[Pkg-owncloud-commits] [php-sabredav] 81/163: Fixed #393 for master

David Prévot taffit at moszumanska.debian.org
Tue May 20 18:54:56 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to annotated tag upstream/2.0.0_beta1
in repository php-sabredav.

commit 8ced1901ff5ba67c5fd1d1000793685bf88db426
Author: Evert Pot <evert at rooftopsolutions.nl>
Date:   Tue Apr 15 00:38:33 2014 -0400

    Fixed #393 for master
---
 tests/Sabre/DAV/PartialUpdate/PluginTest.php | 18 +++++++-----------
 1 file changed, 7 insertions(+), 11 deletions(-)

diff --git a/tests/Sabre/DAV/PartialUpdate/PluginTest.php b/tests/Sabre/DAV/PartialUpdate/PluginTest.php
index f85fa41..88f1e48 100644
--- a/tests/Sabre/DAV/PartialUpdate/PluginTest.php
+++ b/tests/Sabre/DAV/PartialUpdate/PluginTest.php
@@ -128,19 +128,15 @@ class PluginTest extends \Sabre\DAVServerTest {
     public function testPatchNoEndRange() {
 
         $this->node->put('00000');
-        $request = new HTTP\Request(array(
-            'REQUEST_METHOD'      => 'PATCH',
-            'REQUEST_URI'         => '/partial',
-            'HTTP_X_UPDATE_RANGE' => 'bytes=3-',
-            'HTTP_CONTENT_TYPE'   => 'application/x-sabredav-partialupdate',
-            'HTTP_CONTENT_LENGTH' => 3,
-        ));
-        $request->setBody(
-            '111'
-        );
+        $request = new HTTP\Request('PATCH','/partial',[
+            'X-Update-Range' => 'bytes=3-',
+            'Content-Type'   => 'application/x-sabredav-partialupdate',
+            'Content-Length' => '3',
+        ], '111');
+
         $response = $this->request($request);
 
-        $this->assertEquals('HTTP/1.1 204 No Content', $response->status, 'Full response body:' . $response->body);
+        $this->assertEquals(204, $response->getStatus(), 'Full response body:' . $response->getBodyAsString());
         $this->assertEquals('00111', $this->node->get());
 
     }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git



More information about the Pkg-owncloud-commits mailing list