Skip to content

Commit

Permalink
Refactor public link overwrite function
Browse files Browse the repository at this point in the history
  • Loading branch information
SwikritiT committed Aug 6, 2021
1 parent 61d609c commit 069b599
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions tests/acceptance/features/bootstrap/PublicWebDavContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -548,25 +548,28 @@ public function thePublicHasUploadedFileWithPasswordAndContentUsingPublicWebDAVA
/**
* @param string $filename target file name
* @param string $body content to upload
* @param string $publicWebDAVAPIVersion
*
* @return void
*/
public function publiclyOverwritingContent($filename, $body = 'test') {
$this->publicUploadContent($filename, '', $body, false);
public function publiclyOverwritingContent($filename, $body = 'test', $publicWebDAVAPIVersion) {
$this->publicUploadContent($filename, '', $body, false, [], $publicWebDAVAPIVersion);
}

/**
* @When the public overwrites file :filename with content :body using the old WebDAV API
* @When /^the public overwrites file "([^"]*)" with content "([^"]*)" using the (old|new) WebDAV API$/
*
* @param string $filename target file name
* @param string $body content to upload
* @param string $publicWebDAVAPIVersion
*
* @return void
*/
public function thePublicOverwritesFileWithContentUsingOldWebDavApi($filename, $body = 'test') {
public function thePublicOverwritesFileWithContentUsingWebDavApi($filename, $body = 'test', $publicWebDAVAPIVersion) {
$this->publiclyOverwritingContent(
$filename,
$body
$body,
$publicWebDAVAPIVersion
);
}

Expand Down

0 comments on commit 069b599

Please sign in to comment.