|
@@ 54-59 (lines=6) @@
|
| 51 |
|
* @param string $fileSource |
| 52 |
|
* @param string $fileDestination |
| 53 |
|
*/ |
| 54 |
|
public function userMovedFile($user, $fileSource, $fileDestination){ |
| 55 |
|
$fullUrl = substr($this->baseUrl, 0, -4) . $this->davPath; |
| 56 |
|
$headers['Destination'] = $fullUrl . $fileDestination; |
| 57 |
|
$this->response = $this->makeDavRequest($user, "MOVE", $fileSource, $headers); |
| 58 |
|
PHPUnit_Framework_Assert::assertEquals(201, $this->response->getStatusCode()); |
| 59 |
|
} |
| 60 |
|
|
| 61 |
|
/** |
| 62 |
|
* @When /^User "([^"]*)" moves file "([^"]*)" to "([^"]*)"$/ |
|
@@ 67-75 (lines=9) @@
|
| 64 |
|
* @param string $fileSource |
| 65 |
|
* @param string $fileDestination |
| 66 |
|
*/ |
| 67 |
|
public function userMovesFile($user, $fileSource, $fileDestination){ |
| 68 |
|
$fullUrl = substr($this->baseUrl, 0, -4) . $this->davPath; |
| 69 |
|
$headers['Destination'] = $fullUrl . $fileDestination; |
| 70 |
|
try { |
| 71 |
|
$this->response = $this->makeDavRequest($user, "MOVE", $fileSource, $headers); |
| 72 |
|
} catch (\GuzzleHttp\Exception\ClientException $e) { |
| 73 |
|
$this->response = $e->getResponse(); |
| 74 |
|
} |
| 75 |
|
} |
| 76 |
|
|
| 77 |
|
/** |
| 78 |
|
* @When /^User "([^"]*)" copies file "([^"]*)" to "([^"]*)"$/ |
|
@@ 83-91 (lines=9) @@
|
| 80 |
|
* @param string $fileSource |
| 81 |
|
* @param string $fileDestination |
| 82 |
|
*/ |
| 83 |
|
public function userCopiesFile($user, $fileSource, $fileDestination){ |
| 84 |
|
$fullUrl = substr($this->baseUrl, 0, -4) . $this->davPath; |
| 85 |
|
$headers['Destination'] = $fullUrl . $fileDestination; |
| 86 |
|
try { |
| 87 |
|
$this->response = $this->makeDavRequest($user, "COPY", $fileSource, $headers); |
| 88 |
|
} catch (\GuzzleHttp\Exception\ClientException $e) { |
| 89 |
|
$this->response = $e->getResponse(); |
| 90 |
|
} |
| 91 |
|
} |
| 92 |
|
|
| 93 |
|
/** |
| 94 |
|
* @When /^Downloading file "([^"]*)" with range "([^"]*)"$/ |