mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-06 04:09:40 -06:00
add test to check acivities by sharee
Signed-off-by: prashant-gurung899 <prasantgrg777@gmail.com>
This commit is contained in:
@@ -2802,7 +2802,7 @@ class GraphContext implements Context {
|
||||
}
|
||||
|
||||
/**
|
||||
* @When /^user "([^"]*)" lists the activities for (?:folder|file) "([^"]*)" of space "([^"]*)" using the Graph API/
|
||||
* @When /^user "([^"]*)" lists the activities of (?:folder|file) "([^"]*)" from space "([^"]*)" using the Graph API/
|
||||
*
|
||||
* @param string $user
|
||||
* @param string $resource
|
||||
@@ -2823,6 +2823,54 @@ class GraphContext implements Context {
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
* @When user :user tries to list the activities of folder :folder with share mount-point id using the Graph API
|
||||
*
|
||||
* @param string $user
|
||||
* @param string $folder
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function userTriesToListTheActivitiesOfFolderWithShareMountIdPointIdUsingTheGraphApi(string $user, string $folder): void {
|
||||
$resourceId = GraphHelper::getShareMountId(
|
||||
$this->featureContext->getBaseUrl(),
|
||||
$this->featureContext->getStepLineRef(),
|
||||
$user,
|
||||
$this->featureContext->getPasswordForUser($user),
|
||||
$folder
|
||||
);
|
||||
$response = GraphHelper::getActivities(
|
||||
$this->featureContext->getBaseUrl(),
|
||||
$this->featureContext->getStepLineRef(),
|
||||
$user,
|
||||
$this->featureContext->getPasswordForUser($user),
|
||||
$resourceId
|
||||
);
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
* @When user :user tries to list the activities of file :file from space :spaceName owned by user :owner using the Graph API
|
||||
*
|
||||
* @param string $user
|
||||
* @param string $file
|
||||
* @param string $owner
|
||||
* @param string $spaceName
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function userTriesToListActivitiesOfFileFromSpaceOwnedByUserUsingTheGraphApi(string $user, string $file, string $owner, string $spaceName): void {
|
||||
$resourceId = $this->featureContext->spacesContext->getResourceId($owner, $spaceName, $file);
|
||||
$response = GraphHelper::getActivities(
|
||||
$this->featureContext->getBaseUrl(),
|
||||
$this->featureContext->getStepLineRef(),
|
||||
$user,
|
||||
$this->featureContext->getPasswordForUser($user),
|
||||
$resourceId
|
||||
);
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
* @When user :user lists the activities of space :spaceName using the Graph API
|
||||
*
|
||||
@@ -2844,7 +2892,7 @@ class GraphContext implements Context {
|
||||
}
|
||||
|
||||
/**
|
||||
* @When /^user "([^"]*)" lists the activities for (?:folder|file) "([^"]*)" of space "([^"]*)" with (depth|limit) "([^"]*)" using the Graph API/
|
||||
* @When /^user "([^"]*)" lists the activities of (?:folder|file) "([^"]*)" from space "([^"]*)" with (depth|limit) "([^"]*)" using the Graph API/
|
||||
*
|
||||
* @param string $user
|
||||
* @param string $resource
|
||||
|
||||
Reference in New Issue
Block a user