Skip to content

Commit

Permalink
Remove file sharing app
Browse files Browse the repository at this point in the history
  • Loading branch information
amrita-shrestha committed May 4, 2023
1 parent 56a64b9 commit 73c327b
Show file tree
Hide file tree
Showing 72 changed files with 108 additions and 279 deletions.
2 changes: 1 addition & 1 deletion .drone.star
Original file line number Diff line number Diff line change
Expand Up @@ -962,7 +962,7 @@ def wopiValidatorTests(ctx, storage, accounts_hash_difficulty = 4):

def coreApiTests(ctx, part_number = 1, number_of_parts = 1, storage = "ocis", accounts_hash_difficulty = 4):
early_fail = config["apiTests"]["earlyFail"] if "earlyFail" in config["apiTests"] else False
filterTags = "~@skipOnGraph&&~@skipOnOcis-%s-Storage&&~@caldav&&~@carddav" % ("OC" if storage == "owncloud" else "OCIS")
filterTags = "~@skipOnGraph&&~@skipOnOcis-%s-Storage&&~@carddav" % ("OC" if storage == "owncloud" else "OCIS")
expectedFailuresFile = "%s/tests/acceptance/expected-failures-API-on-%s-storage.md" % (dirs["base"], storage.upper())

return {
Expand Down
24 changes: 12 additions & 12 deletions tests/acceptance/expected-failures-API-on-OCIS-storage.md
Original file line number Diff line number Diff line change
Expand Up @@ -710,19 +710,19 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers
- [coreApiTrashbin/trashbinFilesFolders.feature:100](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L100)
- [coreApiTrashbin/trashbinFilesFolders.feature:136](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L136)
- [coreApiTrashbin/trashbinFilesFolders.feature:159](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L159)
- [coreApiTrashbin/trashbinFilesFolders.feature:322](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L322)
- [coreApiTrashbin/trashbinFilesFolders.feature:323](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L323)
- [coreApiTrashbin/trashbinFilesFolders.feature:324](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L324)
- [coreApiTrashbin/trashbinFilesFolders.feature:329](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L329)
- [coreApiTrashbin/trashbinFilesFolders.feature:330](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L330)
- [coreApiTrashbin/trashbinFilesFolders.feature:331](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L331)
- [coreApiTrashbin/trashbinFilesFolders.feature:332](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L332)
- [coreApiTrashbin/trashbinFilesFolders.feature:333](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L333)
- [coreApiTrashbin/trashbinFilesFolders.feature:305](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L305)
- [coreApiTrashbin/trashbinFilesFolders.feature:306](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L306)
- [coreApiTrashbin/trashbinFilesFolders.feature:307](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L307)
- [coreApiTrashbin/trashbinFilesFolders.feature:312](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L312)
- [coreApiTrashbin/trashbinFilesFolders.feature:313](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L313)
- [coreApiTrashbin/trashbinFilesFolders.feature:314](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L314)
- [coreApiTrashbin/trashbinFilesFolders.feature:315](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L315)
- [coreApiTrashbin/trashbinFilesFolders.feature:316](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L316)
- [coreApiTrashbin/trashbinFilesFolders.feature:317](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L317)
- [coreApiTrashbin/trashbinFilesFolders.feature:334](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L334)
- [coreApiTrashbin/trashbinFilesFolders.feature:351](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L351)
- [coreApiTrashbin/trashbinFilesFolders.feature:371](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L371)
- [coreApiTrashbin/trashbinFilesFolders.feature:425](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L425)
- [coreApiTrashbin/trashbinFilesFolders.feature:462](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L462)
- [coreApiTrashbin/trashbinFilesFolders.feature:354](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L354)
- [coreApiTrashbin/trashbinFilesFolders.feature:408](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L408)
- [coreApiTrashbin/trashbinFilesFolders.feature:445](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L445)

#### [Default capabilities for normal user and admin user not same as in oC-core](https://github.com/owncloud/ocis/issues/1285)
- [coreApiCapabilities/capabilities.feature:11](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiCapabilities/capabilities.feature#L11)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @skipOnReva
@api @skipOnReva
Feature: sharing
As a user
I want to be able to share files when passwords are stored with the full hash difficulty
Expand Down
4 changes: 2 additions & 2 deletions tests/acceptance/features/apiSpacesShares/checksum.feature
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Feature: checksums
And using spaces DAV path
And user "Brian" has been created with default attributes and without skeleton files

@files_sharing-app-required @issue-1291
@issue-1291
Scenario: sharing a file with checksum should return the checksum in the propfind using new DAV path
Given user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myChecksumFile.txt" with checksum "MD5:d70b40f177b14b470d1756a3c12b963a"
And user "Alice" has shared file "/myChecksumFile.txt" with user "Brian"
Expand All @@ -19,7 +19,7 @@ Feature: checksums
Then the HTTP status code should be "207"
And the webdav checksum should match "SHA1:3ee962b839762adb0ad8ba6023a4690be478de6f MD5:d70b40f177b14b470d1756a3c12b963a ADLER32:8ae90960"

@files_sharing-app-required @issue-1291
@issue-1291
Scenario: modifying a shared file should return correct checksum in the propfind using new DAV path
Given user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myChecksumFile.txt" with checksum "MD5:d70b40f177b14b470d1756a3c12b963a"
And user "Alice" has shared file "/myChecksumFile.txt" with user "Brian"
Expand Down
148 changes: 0 additions & 148 deletions tests/acceptance/features/bootstrap/FeatureContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -1867,40 +1867,6 @@ public function createFileOnServerWithContent(
);
}

/**
* @Given file :filename with text :text has been created in local storage on the server
*
* @param string $filename
* @param string $text
*
* @return void
* @throws Exception
*/
public function fileHasBeenCreatedInLocalStorageWithText(string $filename, string $text): void {
$this->createFileOnServerWithContent(
LOCAL_STORAGE_DIR_ON_REMOTE_SERVER . "/$filename",
$text
);
}

/**
* @Given file :filename has been deleted from local storage on the server
*
* @param string $filename
*
* @return void
* @throws Exception
*/
public function fileHasBeenDeletedInLocalStorage(string $filename): void {
SetupHelper::deleteFileOnServer(
LOCAL_STORAGE_DIR_ON_REMOTE_SERVER . "/$filename",
$this->getStepLineRef(),
$this->getBaseUrl(),
$this->getAdminUsername(),
$this->getAdminPassword()
);
}

/**
* @param string $user
*
Expand Down Expand Up @@ -2185,83 +2151,6 @@ public function theAdministratorRequestsStatusPhp(): void {
$this->response = $this->getStatusPhp();
}

/**
* @When the administrator creates file :path with content :content in local storage using the testing API
*
* @param string $path
* @param string $content
*
* @return void
*/
public function theAdministratorCreatesFileUsingTheTestingApi(string $path, string $content): void {
$this->theAdministratorCreatesFileWithContentInLocalStorageUsingTheTestingApi(
$path,
$content,
'local_storage'
);
}

/**
* @Given the administrator has created file :path with content :content in local storage using the testing API
*
* @param string $path
* @param string $content
*
* @return void
*/
public function theAdministratorHasCreatedFileUsingTheTestingApi(string $path, string $content): void {
$this->theAdministratorHasCreatedFileWithContentInLocalStorageUsingTheTestingApi(
$path,
$content,
'local_storage'
);
}

/**
* @When the administrator creates file :path with content :content in local storage :mountPoint using the testing API
*
* @param string $path
* @param string $content
* @param string $mountPoint
*
* @return void
* @throws Exception
*/
public function theAdministratorCreatesFileWithContentInLocalStorageUsingTheTestingApi(
string $path,
string $content,
string $mountPoint
): void {
$response = $this->copyContentToFileInTemporaryStorageOnSystemUnderTest(
"$mountPoint/$path",
$content
);
$this->setResponse($response);
}

/**
* @Given the administrator has created file :path with content :content in local storage :mountPoint
*
* @param string $path
* @param string $content
* @param string $mountPoint
*
* @return void
* @throws Exception
*/
public function theAdministratorHasCreatedFileWithContentInLocalStorageUsingTheTestingApi(
string $path,
string $content,
string $mountPoint
): void {
$this->theAdministratorCreatesFileWithContentInLocalStorageUsingTheTestingApi(
$path,
$content,
$mountPoint
);
$this->theHTTPStatusCodeShouldBeSuccess();
}

/**
* Copy a file from the test-runner to the temporary storage directory on
* the system-under-test. This uses the testing app to push the file into
Expand Down Expand Up @@ -2321,28 +2210,6 @@ public function copyContentToFileInTemporaryStorageOnSystemUnderTest(
);
}

/**
* @When the administrator deletes file :path in local storage using the testing API
*
* @param string $path
*
* @return void
*/
public function theAdministratorDeletesFileInLocalStorageUsingTheTestingApi(string $path): void {
$user = $this->getAdminUsername();
$response = OcsApiHelper::sendRequest(
$this->getBaseUrl(),
$user,
$this->getAdminPassword(),
'DELETE',
"/apps/testing/api/v1/file",
$this->getStepLineRef(),
['file' => LOCAL_STORAGE_DIR_ON_REMOTE_SERVER . "/$path"],
$this->getOcsApiVersion()
);
$this->setResponse($response);
}

/**
* @Given a file with the size of :size bytes and the name :name has been created locally
*
Expand Down Expand Up @@ -2612,21 +2479,6 @@ public function moveFileInServerRoot(string $path, string $target): void {
$this->setResponse($response);
}

/**
* @When the local storage mount for :mount is renamed to :target
*
* @param string $mount
* @param string $target
*
* @return void
*/
public function theLocalStorageMountForIsRenamedTo(string $mount, string $target): void {
$mountPath = TEMPORARY_STORAGE_DIR_ON_REMOTE_SERVER . "/" . ltrim($mount, '/');
$targetPath = TEMPORARY_STORAGE_DIR_ON_REMOTE_SERVER . "/" . ltrim($target, '/');

$this->moveFileInServerRoot($mountPath, $targetPath);
}

/**
* @Then the file :path with content :content should exist in the server root
*
Expand Down
6 changes: 0 additions & 6 deletions tests/acceptance/features/bootstrap/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,3 @@
if (!\defined('TEMPORARY_STORAGE_DIR_ON_REMOTE_SERVER')) {
\define('TEMPORARY_STORAGE_DIR_ON_REMOTE_SERVER', ACCEPTANCE_TEST_DIR_ON_REMOTE_SERVER . '/server_tmp');
}

// The following directory is created, used, and deleted by tests that need to
// use some "local external storage" on the server.
if (!\defined('LOCAL_STORAGE_DIR_ON_REMOTE_SERVER')) {
\define('LOCAL_STORAGE_DIR_ON_REMOTE_SERVER', TEMPORARY_STORAGE_DIR_ON_REMOTE_SERVER . '/local_storage');
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: auth
As a user
I want to send delete request with wrong password
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: auth
As a user
I want to send GET request to various endpoints
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: auth
As a user
I want to send POST request to various endpoints
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: auth
As a user
I want to send PUT request to various endpoints
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api .10.0
@api
Feature: make webdav request with special urls
As a user
I want to make webdav request with special urls
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: capabilities
As an admin
I want to list the capabilities
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: default capabilities for normal user
As a user
I want to list capabilities
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: favorite
As a user
I want to favorite the shared resources
Expand Down
4 changes: 2 additions & 2 deletions tests/acceptance/features/coreApiMain/checksums.feature
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ Feature: checksums
| dav_version |
| spaces |

@files_sharing-app-required @issue-1291
@issue-1291
Scenario Outline: sharing a file with checksum should return the checksum in the propfind using new DAV path
Given auto-accept shares has been disabled
And using <dav_version> DAV path
Expand All @@ -190,7 +190,7 @@ Feature: checksums
| dav_version |
| new |

@files_sharing-app-required @issue-1291
@issue-1291
Scenario Outline: modifying a shared file should return correct checksum in the propfind using new DAV path
Given auto-accept shares has been disabled
And using <dav_version> DAV path
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: Sharing resources with different case names with the sharee and checking the coexistence of resources on sharee/receivers side
As a user
I want to share resources with case sensitive names
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: resources shared with the same name are received with unique names
As a user
I want to share resources with same name
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1327
@api @issue-1327
Feature: shares are received in the default folder for received shares
As a user
I want to share the default Shares folder
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: sharing works when a username and group name are the same
As a user
I want to share resources with group and users having same name
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: share resources where the sharee receives the share in multiple ways
As a user
I want to receives the same resource share from multiple channels
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1328
@api @issue-1328
Feature: share resources with a disabled user
As a user
I want to share resources to disabled user
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: cannot share resources with invalid permissions
As a user
I want to share resources with invalid permission
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: sharing
As a user
I want to share resources to others
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1328 @issue-1289
@api @issue-1328 @issue-1289
Feature: sharing
As a user
I want to delete shares
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1289 @issue-1328
@api @issue-1289 @issue-1328
Feature: accept/decline shares coming from internal users
As a user
I want to have control of which received shares I accept
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required
@api
Feature: accept/decline shares coming from internal users to the Shares folder
As a user
I want to have control of which received shares I accept
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1328 @issues-1289
@api @issue-1328 @issues-1289
Feature: sharing

Background:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@api @files_sharing-app-required @issue-1289 @issue-1328
@api @issue-1289 @issue-1328
Feature: sharing

Background:
Expand Down
Loading

0 comments on commit 73c327b

Please sign in to comment.