aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php
diff options
context:
space:
mode:
authorKlaus Weidenbach <Klaus.Weidenbach@gmx.net>2014-06-28 22:28:08 +0200
committerKlaus Weidenbach <Klaus.Weidenbach@gmx.net>2014-06-29 01:17:07 +0200
commit03b31d113ea316c8384a4cbf3d27ca22bb528eac (patch)
tree92ed87436b09ab806f9effff08145408044d77f4 /vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php
parentf49b74c5f6ebe57937fb6dfea7d2e917f4680ce9 (diff)
downloadvolse-hubzilla-03b31d113ea316c8384a4cbf3d27ca22bb528eac.tar.gz
volse-hubzilla-03b31d113ea316c8384a4cbf3d27ca22bb528eac.tar.bz2
volse-hubzilla-03b31d113ea316c8384a4cbf3d27ca22bb528eac.zip
Update SabreDAV from 1.8.9 to 1.8.10.
Diffstat (limited to 'vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php')
-rw-r--r--vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php142
1 files changed, 0 insertions, 142 deletions
diff --git a/vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php b/vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php
index afcd5c98f..21e0ab2ea 100644
--- a/vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php
+++ b/vendor/sabre/dav/tests/Sabre/DAV/ServerSimpleTest.php
@@ -175,148 +175,6 @@ class ServerSimpleTest extends AbstractServer{
}
- function testPut() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/testput.txt',
- 'REQUEST_METHOD' => 'PUT',
- );
-
- $request = new HTTP\Request($serverVars);
- $request->setBody('Testing new file');
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals('', $this->response->body);
- $this->assertEquals('HTTP/1.1 201 Created',$this->response->status);
- $this->assertEquals(array(
- "Content-Length" => "0",
- ), $this->response->headers);
-
- $this->assertEquals('Testing new file',file_get_contents($this->tempDir . '/testput.txt'));
-
- }
-
- function testPutAlreadyExists() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/test.txt',
- 'REQUEST_METHOD' => 'PUT',
- 'HTTP_IF_NONE_MATCH' => '*',
- );
-
- $request = new HTTP\Request($serverVars);
- $request->setBody('Testing new file');
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals(array(
- 'Content-Type' => 'application/xml; charset=utf-8',
- ),$this->response->headers);
-
- $this->assertEquals('HTTP/1.1 412 Precondition failed',$this->response->status);
- $this->assertNotEquals('Testing new file',file_get_contents($this->tempDir . '/test.txt'));
-
- }
-
- function testPutUpdate() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/test.txt',
- 'REQUEST_METHOD' => 'PUT',
- );
-
- $request = new HTTP\Request($serverVars);
- $request->setBody('Testing updated file');
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals('0', $this->response->headers['Content-Length']);
-
- $this->assertEquals('HTTP/1.1 204 No Content',$this->response->status);
- $this->assertEquals('', $this->response->body);
- $this->assertEquals('Testing updated file',file_get_contents($this->tempDir . '/test.txt'));
-
- }
-
- function testPutNoParentCollection() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/test.txt/item.txt',
- 'REQUEST_METHOD' => 'PUT',
- );
-
- $request = new HTTP\Request($serverVars);
- $request->setBody('Testing updated file');
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals('HTTP/1.1 409 Conflict',$this->response->status);
-
- }
-
- function testPutContentRange() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/testput.txt',
- 'REQUEST_METHOD' => 'PUT',
- 'HTTP_CONTENT_RANGE' => 'bytes/100-200',
- );
-
- $request = new HTTP\Request($serverVars);
- $request->setBody('Testing new file');
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals('HTTP/1.1 501 Not Implemented',$this->response->status);
-
- }
-
-
- function testDelete() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/test.txt',
- 'REQUEST_METHOD' => 'DELETE',
- );
-
- $request = new HTTP\Request($serverVars);
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals(array(
- 'Content-Length' => '0',
- ),$this->response->headers);
-
- $this->assertEquals('HTTP/1.1 204 No Content',$this->response->status);
- $this->assertEquals('', $this->response->body);
- $this->assertFalse(file_exists($this->tempDir . '/test.txt'));
-
- }
-
- function testDeleteDirectory() {
-
- $serverVars = array(
- 'REQUEST_URI' => '/testcol',
- 'REQUEST_METHOD' => 'DELETE',
- );
-
- mkdir($this->tempDir.'/testcol');
- file_put_contents($this->tempDir.'/testcol/test.txt','Hi! I\'m a file with a short lifespan');
-
- $request = new HTTP\Request($serverVars);
- $this->server->httpRequest = ($request);
- $this->server->exec();
-
- $this->assertEquals(array(
- 'Content-Length' => '0',
- ),$this->response->headers);
- $this->assertEquals('HTTP/1.1 204 No Content',$this->response->status);
- $this->assertEquals('', $this->response->body);
- $this->assertFalse(file_exists($this->tempDir . '/col'));
-
- }
-
function testOptions() {
$serverVars = array(