aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/sabre/dav/tests/Sabre/CardDAV
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2020-01-12 09:18:07 +0000
committerMario <mario@mariovavti.com>2020-01-12 09:18:07 +0000
commit8cb968c4b03e5d5462edec56f31625e9f15a6a15 (patch)
treeccd1974ee57d17492a25846b2e4fae28b97c1e2f /vendor/sabre/dav/tests/Sabre/CardDAV
parentf645c6f3a57bf5f53bbb2bde362b2447f725c977 (diff)
downloadvolse-hubzilla-8cb968c4b03e5d5462edec56f31625e9f15a6a15.tar.gz
volse-hubzilla-8cb968c4b03e5d5462edec56f31625e9f15a6a15.tar.bz2
volse-hubzilla-8cb968c4b03e5d5462edec56f31625e9f15a6a15.zip
composer update sabre/dav
Diffstat (limited to 'vendor/sabre/dav/tests/Sabre/CardDAV')
-rw-r--r--vendor/sabre/dav/tests/Sabre/CardDAV/AddressBookQueryTest.php37
-rw-r--r--vendor/sabre/dav/tests/Sabre/CardDAV/MultiGetTest.php10
-rw-r--r--vendor/sabre/dav/tests/Sabre/CardDAV/VCFExportTest.php4
-rw-r--r--vendor/sabre/dav/tests/Sabre/CardDAV/ValidateVCardTest.php4
4 files changed, 32 insertions, 23 deletions
diff --git a/vendor/sabre/dav/tests/Sabre/CardDAV/AddressBookQueryTest.php b/vendor/sabre/dav/tests/Sabre/CardDAV/AddressBookQueryTest.php
index 6e7e13106..fe047fb84 100644
--- a/vendor/sabre/dav/tests/Sabre/CardDAV/AddressBookQueryTest.php
+++ b/vendor/sabre/dav/tests/Sabre/CardDAV/AddressBookQueryTest.php
@@ -39,12 +39,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([
'/addressbooks/user1/book1/card1' => [
@@ -87,12 +88,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([
'/addressbooks/user1/book1/card1' => [
@@ -130,12 +132,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([], $result);
}
@@ -168,12 +171,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([
'/addressbooks/user1/book1/card1' => [
@@ -209,12 +213,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$vobjVersion = \Sabre\VObject\Version::VERSION;
@@ -253,12 +258,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$vobjVersion = \Sabre\VObject\Version::VERSION;
@@ -297,7 +303,7 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(415, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $this->assertEquals(415, $response->status, 'Incorrect status code. Full response body:'.$response->getBodyAsString());
}
public function testAddressBookProperties()
@@ -328,12 +334,13 @@ class AddressBookQueryTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([
'/addressbooks/user1/book3/card3' => [
diff --git a/vendor/sabre/dav/tests/Sabre/CardDAV/MultiGetTest.php b/vendor/sabre/dav/tests/Sabre/CardDAV/MultiGetTest.php
index 4e3276ed3..6fdfcd07a 100644
--- a/vendor/sabre/dav/tests/Sabre/CardDAV/MultiGetTest.php
+++ b/vendor/sabre/dav/tests/Sabre/CardDAV/MultiGetTest.php
@@ -36,12 +36,13 @@ class MultiGetTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$this->assertEquals([
'/addressbooks/user1/book1/card1' => [
@@ -78,12 +79,13 @@ class MultiGetTest extends AbstractPluginTest
$this->server->exec();
- $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$response->body);
+ $bodyAsString = $response->getBodyAsString();
+ $this->assertEquals(207, $response->status, 'Incorrect status code. Full response body:'.$bodyAsString);
// using the client for parsing
$client = new DAV\Client(['baseUri' => '/']);
- $result = $client->parseMultiStatus($response->body);
+ $result = $client->parseMultiStatus($bodyAsString);
$prodId = 'PRODID:-//Sabre//Sabre VObject '.\Sabre\VObject\Version::VERSION.'//EN';
diff --git a/vendor/sabre/dav/tests/Sabre/CardDAV/VCFExportTest.php b/vendor/sabre/dav/tests/Sabre/CardDAV/VCFExportTest.php
index d8acc3c14..48477d7f2 100644
--- a/vendor/sabre/dav/tests/Sabre/CardDAV/VCFExportTest.php
+++ b/vendor/sabre/dav/tests/Sabre/CardDAV/VCFExportTest.php
@@ -57,7 +57,7 @@ class VCFExportTest extends \Sabre\DAVServerTest
]);
$response = $this->request($request);
- $this->assertEquals(200, $response->status, $response->body);
+ $this->assertEquals(200, $response->status, $response->getBodyAsString());
$expected = 'BEGIN:VCARD
FN:Person1
@@ -75,7 +75,7 @@ END:VCARD
// We actually expected windows line endings
$expected = str_replace("\n", "\r\n", $expected);
- $this->assertEquals($expected, $response->body);
+ $this->assertEquals($expected, $response->getBodyAsString());
}
public function testBrowserIntegration()
diff --git a/vendor/sabre/dav/tests/Sabre/CardDAV/ValidateVCardTest.php b/vendor/sabre/dav/tests/Sabre/CardDAV/ValidateVCardTest.php
index 2317b86cc..a9be169c0 100644
--- a/vendor/sabre/dav/tests/Sabre/CardDAV/ValidateVCardTest.php
+++ b/vendor/sabre/dav/tests/Sabre/CardDAV/ValidateVCardTest.php
@@ -240,7 +240,7 @@ VCF;
$response = $this->request($request);
- $this->assertEquals(201, $response->status, 'Incorrect status returned! Full response body: '.$response->body);
+ $this->assertEquals(201, $response->status, 'Incorrect status returned! Full response body: '.$response->getBodyAsString());
$foo = $this->cardBackend->getCard('addressbook1', 'blabla.vcf');
$this->assertEquals("BEGIN:VCARD\r\nVERSION:4.0\r\nUID:foo\r\nFN:FirstName LastName\r\nEND:VCARD\r\n", $foo['carddata']);
@@ -256,7 +256,7 @@ VCF;
$response = $this->request($request);
- $this->assertEquals(415, $response->status, 'Incorrect status returned! Full response body: '.$response->body);
+ $this->assertEquals(415, $response->status, 'Incorrect status returned! Full response body: '.$response->getBodyAsString());
}
public function testUpdateFile()