aboutsummaryrefslogtreecommitdiffstats
path: root/apps/dav/tests/unit/Connector/Sabre/FileTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/tests/unit/Connector/Sabre/FileTest.php')
-rw-r--r--apps/dav/tests/unit/Connector/Sabre/FileTest.php68
1 files changed, 34 insertions, 34 deletions
diff --git a/apps/dav/tests/unit/Connector/Sabre/FileTest.php b/apps/dav/tests/unit/Connector/Sabre/FileTest.php
index 4c87351116c..d366726e919 100644
--- a/apps/dav/tests/unit/Connector/Sabre/FileTest.php
+++ b/apps/dav/tests/unit/Connector/Sabre/FileTest.php
@@ -350,52 +350,52 @@ class FileTest extends TestCase {
public function legalMtimeProvider() {
return [
"string" => [
- 'HTTP_X_OC_MTIME' => "string",
- 'expected result' => null
+ 'HTTP_X_OC_MTIME' => "string",
+ 'expected result' => null
],
"castable string (int)" => [
- 'HTTP_X_OC_MTIME' => "34",
- 'expected result' => 34
+ 'HTTP_X_OC_MTIME' => "34",
+ 'expected result' => 34
],
"castable string (float)" => [
- 'HTTP_X_OC_MTIME' => "34.56",
- 'expected result' => 34
+ 'HTTP_X_OC_MTIME' => "34.56",
+ 'expected result' => 34
],
"float" => [
- 'HTTP_X_OC_MTIME' => 34.56,
- 'expected result' => 34
+ 'HTTP_X_OC_MTIME' => 34.56,
+ 'expected result' => 34
],
"zero" => [
- 'HTTP_X_OC_MTIME' => 0,
- 'expected result' => 0
+ 'HTTP_X_OC_MTIME' => 0,
+ 'expected result' => 0
],
"zero string" => [
- 'HTTP_X_OC_MTIME' => "0",
- 'expected result' => 0
+ 'HTTP_X_OC_MTIME' => "0",
+ 'expected result' => 0
],
"negative zero string" => [
- 'HTTP_X_OC_MTIME' => "-0",
- 'expected result' => 0
+ 'HTTP_X_OC_MTIME' => "-0",
+ 'expected result' => 0
],
"string starting with number following by char" => [
- 'HTTP_X_OC_MTIME' => "2345asdf",
- 'expected result' => null
+ 'HTTP_X_OC_MTIME' => "2345asdf",
+ 'expected result' => null
],
"string castable hex int" => [
- 'HTTP_X_OC_MTIME' => "0x45adf",
- 'expected result' => null
+ 'HTTP_X_OC_MTIME' => "0x45adf",
+ 'expected result' => null
],
"string that looks like invalid hex int" => [
- 'HTTP_X_OC_MTIME' => "0x123g",
- 'expected result' => null
+ 'HTTP_X_OC_MTIME' => "0x123g",
+ 'expected result' => null
],
"negative int" => [
- 'HTTP_X_OC_MTIME' => -34,
- 'expected result' => -34
+ 'HTTP_X_OC_MTIME' => -34,
+ 'expected result' => -34
],
"negative float" => [
- 'HTTP_X_OC_MTIME' => -34.43,
- 'expected result' => -34
+ 'HTTP_X_OC_MTIME' => -34.43,
+ 'expected result' => -34
],
];
}
@@ -406,9 +406,9 @@ class FileTest extends TestCase {
*/
public function testPutSingleFileLegalMtime($requestMtime, $resultMtime) {
$request = new \OC\AppFramework\Http\Request([
- 'server' => [
- 'HTTP_X_OC_MTIME' => $requestMtime,
- ]
+ 'server' => [
+ 'HTTP_X_OC_MTIME' => $requestMtime,
+ ]
], null, $this->config, null);
$file = 'foo.txt';
@@ -430,9 +430,9 @@ class FileTest extends TestCase {
*/
public function testChunkedPutLegalMtime($requestMtime, $resultMtime) {
$request = new \OC\AppFramework\Http\Request([
- 'server' => [
- 'HTTP_X_OC_MTIME' => $requestMtime,
- ]
+ 'server' => [
+ 'HTTP_X_OC_MTIME' => $requestMtime,
+ ]
], null, $this->config, null);
$_SERVER['HTTP_OC_CHUNKED'] = true;
@@ -1105,10 +1105,10 @@ class FileTest extends TestCase {
$userView = Filesystem::getView();
}
return [
- "filesize" => $userView->filesize($path),
- "mtime" => $userView->filemtime($path),
- "filetype" => $userView->filetype($path),
- "mimetype" => $userView->getMimeType($path)
+ "filesize" => $userView->filesize($path),
+ "mtime" => $userView->filemtime($path),
+ "filetype" => $userView->filetype($path),
+ "mimetype" => $userView->getMimeType($path)
];
}