mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-05-08 20:40:16 -05:00
Remove folder lock related tests from ocis
This commit is contained in:
committed by
Phil Davis
parent
50471af588
commit
9489e179dd
@@ -30,7 +30,6 @@ default:
|
||||
- PublicWebDavContext:
|
||||
- TrashbinContext:
|
||||
- WebDavPropertiesContext:
|
||||
- WebDavLockingContext:
|
||||
|
||||
apiSpaces:
|
||||
paths:
|
||||
@@ -49,7 +48,6 @@ default:
|
||||
- SearchContext:
|
||||
- TrashbinContext:
|
||||
- WebDavPropertiesContext:
|
||||
- WebDavLockingContext:
|
||||
- TUSContext:
|
||||
- SpacesTUSContext:
|
||||
|
||||
@@ -70,7 +68,6 @@ default:
|
||||
- FavoritesContext:
|
||||
- TrashbinContext:
|
||||
- WebDavPropertiesContext:
|
||||
- WebDavLockingContext:
|
||||
|
||||
apiGraph:
|
||||
paths:
|
||||
|
||||
@@ -1,90 +0,0 @@
|
||||
@api @skipOnOcV10
|
||||
Feature: lock
|
||||
# Note: This Feature includes all the tests from core (apiWebdavLock suite) related to /Shares since in core no implementation is there for space Shares Jail
|
||||
|
||||
Background:
|
||||
Given these users have been created with default attributes and without skeleton files:
|
||||
| username |
|
||||
| Alice |
|
||||
| Brian |
|
||||
| Carol |
|
||||
And user "Alice" has created folder "PARENT"
|
||||
And user "Brian" has created folder "PARENT"
|
||||
And user "Carol" has created folder "PARENT"
|
||||
And using spaces DAV path
|
||||
|
||||
|
||||
Scenario Outline: lock should propagate correctly when uploaded to a reshare that was locked by the owner
|
||||
Given user "Alice" has shared folder "PARENT" with user "Brian"
|
||||
And user "Brian" has accepted share "/PARENT" offered by user "Alice"
|
||||
And user "Brian" has shared the following entity "PARENT" inside of space "Shares Jail" with user "Carol" with role "editor"
|
||||
And user "Carol" has accepted share "/PARENT" offered by user "Brian"
|
||||
And user "Alice" has locked folder "/PARENT" inside space "Personal" setting the following properties
|
||||
| lockscope | <lock-scope> |
|
||||
When user "Carol" uploads a file inside space "Shares Jail" with content "uploaded by carol" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Brian" uploads a file inside space "Shares Jail" with content "uploaded by brian" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Alice" uploads file "filesForUpload/textfile.txt" to "/PARENT/textfile.txt" using the WebDAV API
|
||||
Then the HTTP status code of responses on all endpoints should be "423"
|
||||
And as "Alice" file "/PARENT/textfile.txt" should not exist
|
||||
Examples:
|
||||
| lock-scope |
|
||||
| shared |
|
||||
| exclusive |
|
||||
|
||||
|
||||
Scenario Outline: lock should propagate correctly when uploaded overwriting to a reshare that was locked by the owner
|
||||
Given user "Alice" has uploaded file with content "ownCloud test text file parent" to "PARENT/parent.txt"
|
||||
And user "Alice" has shared folder "PARENT" with user "Brian"
|
||||
And user "Brian" has accepted share "/PARENT" offered by user "Alice"
|
||||
And user "Brian" has shared the following entity "PARENT" inside of space "Shares Jail" with user "Carol" with role "editor"
|
||||
And user "Carol" has accepted share "/PARENT" offered by user "Brian"
|
||||
And user "Alice" has locked folder "/PARENT" inside space "Personal" setting the following properties
|
||||
| lockscope | <lock-scope> |
|
||||
When user "Carol" uploads a file inside space "Shares Jail" with content "uploaded by carol" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Brian" uploads a file inside space "Shares Jail" with content "uploaded by brian" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Alice" uploads file "filesForUpload/textfile.txt" to "/PARENT/parent.txt" using the WebDAV API
|
||||
Then the HTTP status code of responses on all endpoints should be "423"
|
||||
And the content of file "/PARENT/parent.txt" for user "Alice" should be "ownCloud test text file parent"
|
||||
Examples:
|
||||
| lock-scope |
|
||||
| shared |
|
||||
| exclusive |
|
||||
|
||||
|
||||
Scenario Outline: lock should propagate correctly when the public uploads to a reshared share that was locked by the original owner
|
||||
Given user "Alice" has shared folder "PARENT" with user "Brian"
|
||||
And user "Brian" has accepted share "/PARENT" offered by user "Alice"
|
||||
And user "Brian" has shared the following entity "PARENT" inside of space "Shares Jail" with user "Carol" with role "editor"
|
||||
And user "Carol" has accepted share "/PARENT" offered by user "Brian"
|
||||
And user "Carol" has created a public link share inside of space "Shares Jail" with settings:
|
||||
| path | PARENT |
|
||||
| shareType | 3 |
|
||||
| permissions | 15 |
|
||||
| name | public link |
|
||||
And user "Alice" has locked folder "/PARENT" inside space "Personal" setting the following properties
|
||||
| lockscope | <lock-scope> |
|
||||
When the public uploads file "test.txt" with content "test" using the new public WebDAV API
|
||||
Then the HTTP status code should be "423"
|
||||
And as "Alice" file "/PARENT/test.txt" should not exist
|
||||
Examples:
|
||||
| lock-scope |
|
||||
| shared |
|
||||
| exclusive |
|
||||
|
||||
|
||||
Scenario Outline: lock should propagate correctly when uploaded to a reshare that was locked by the resharing user
|
||||
Given user "Alice" has shared folder "PARENT" with user "Brian"
|
||||
And user "Brian" has accepted share "/PARENT" offered by user "Alice"
|
||||
And user "Brian" has shared the following entity "PARENT" inside of space "Shares Jail" with user "Carol" with role "editor"
|
||||
And user "Carol" has accepted share "/PARENT" offered by user "Brian"
|
||||
And user "Brian" has locked folder "/PARENT" inside space "Shares Jail" setting the following properties
|
||||
| lockscope | <lock-scope> |
|
||||
When user "Carol" uploads a file inside space "Shares Jail" with content "uploaded by carol" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Brian" uploads a file inside space "Shares Jail" with content "uploaded by brian" to "PARENT/textfile.txt" using the WebDAV API
|
||||
And user "Alice" uploads file "filesForUpload/textfile.txt" to "/PARENT/textfile.txt" using the WebDAV API
|
||||
Then the HTTP status code of responses on all endpoints should be "423"
|
||||
And as "Alice" file "/PARENT/textfile.txt" should not exist
|
||||
Examples:
|
||||
| lock-scope |
|
||||
| shared |
|
||||
| exclusive |
|
||||
@@ -65,11 +65,6 @@ class SpacesContext implements Context {
|
||||
*/
|
||||
private FavoritesContext $favoritesContext;
|
||||
|
||||
/**
|
||||
* @var WebDavLockingContext
|
||||
*/
|
||||
private WebDavLockingContext $webDavLockingContext;
|
||||
|
||||
/**
|
||||
* @var ChecksumContext
|
||||
*/
|
||||
@@ -460,7 +455,6 @@ class SpacesContext implements Context {
|
||||
$this->trashbinContext = $environment->getContext('TrashbinContext');
|
||||
$this->webDavPropertiesContext = $environment->getContext('WebDavPropertiesContext');
|
||||
$this->favoritesContext = $environment->getContext('FavoritesContext');
|
||||
$this->webDavLockingContext = $environment->getContext('WebDavLockingContext');
|
||||
$this->checksumContext = $environment->getContext('ChecksumContext');
|
||||
// Run the BeforeScenario function in OCSContext to set it up correctly
|
||||
$this->ocsContext->before($scope);
|
||||
@@ -2988,22 +2982,6 @@ class SpacesContext implements Context {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @Given /^user "([^"]*)" has locked folder "([^"]*)" inside space "([^"]*)" setting the following properties$/
|
||||
*
|
||||
* @param string $user
|
||||
* @param string $resource
|
||||
* @param TableNode $properties
|
||||
* @param string $spaceName
|
||||
*
|
||||
* @return void
|
||||
* @throws Exception | GuzzleException
|
||||
*/
|
||||
public function userHasLockedResourceOfSpace(string $user, string $resource, TableNode $properties, string $spaceName): void {
|
||||
$this->setSpaceIDByName($user, $spaceName);
|
||||
$this->webDavLockingContext->lockFileUsingWebDavAPI($user, $resource, $properties);
|
||||
}
|
||||
|
||||
/**
|
||||
* @When /^user "([^"]*)" creates a public link share of the space "([^"]*)" with settings:$/
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user