11 $xml =
'<?xml version="1.0"?>
12<d:sync-collection xmlns:d="DAV:">
14 <d:sync-level>1</d:sync-level>
21 $result = $this->
parse(
$xml, [
'{DAV:}sync-collection' =>
'Sabre\\DAV\\Xml\\Request\\SyncCollectionReport']);
25 $elem->properties = [
'{DAV:}foo'];
27 $this->assertEquals($elem,
$result[
'value']);
34 $xml =
'<?xml version="1.0"?>
35<d:sync-collection xmlns:d="DAV:">
37 <d:sync-level>1</d:sync-level>
41 <d:limit><d:nresults>5</d:nresults></d:limit>
45 $result = $this->
parse(
$xml, [
'{DAV:}sync-collection' =>
'Sabre\\DAV\\Xml\\Request\\SyncCollectionReport']);
49 $elem->properties = [
'{DAV:}foo'];
52 $this->assertEquals($elem,
$result[
'value']);
59 $xml =
'<?xml version="1.0"?>
60<d:sync-collection xmlns:d="DAV:">
62 <d:sync-level>infinity</d:sync-level>
69 $result = $this->
parse(
$xml, [
'{DAV:}sync-collection' =>
'Sabre\\DAV\\Xml\\Request\\SyncCollectionReport']);
73 $elem->properties = [
'{DAV:}foo'];
75 $this->assertEquals($elem,
$result[
'value']);
84 $xml =
'<?xml version="1.0"?>
85<d:sync-collection xmlns:d="DAV:">
90 $result = $this->
parse(
$xml, [
'{DAV:}sync-collection' =>
'Sabre\\DAV\\Xml\\Request\\SyncCollectionReport']);
An exception for terminatinating execution or to throw for unit testing.
const DEPTH_INFINITY
Infinity is used for some request supporting the HTTP Depth header and indicates that the operation s...
SyncCollection request parser.
testDeserializeInfinity()
testDeserializeMissingElem()
@expectedException \Sabre\DAV\Exception\BadRequest
parse($xml, array $elementMap=[])