[tests-only] add file/folder creation and list sharedByMe of link shares (#9150)
* test: add more edge-case tests for file/folder creation * test: add list sharedByMe tests for link shares * test: fix tests * test: list sharedByMe of drive link share * test: add issue tag * test: split scenario
This commit is contained in:
@@ -2519,9 +2519,9 @@ class GraphContext implements Context {
|
||||
* @param string $user
|
||||
* @param bool $waitForCacheExpiry
|
||||
*
|
||||
* @return void
|
||||
* @return ResponseInterface
|
||||
*/
|
||||
public function listSharesSharedByMe(string $user, bool $waitForCacheExpiry = false) {
|
||||
public function listSharesSharedByMe(string $user, bool $waitForCacheExpiry = false): ResponseInterface {
|
||||
$credentials = $this->getAdminOrUserCredentials($user);
|
||||
if ($waitForCacheExpiry) {
|
||||
// ENV (GRAPH_SPACES_GROUPS_CACHE_TTL | GRAPH_SPACES_USERS_CACHE_TTL) is set default to 60 sec
|
||||
@@ -2529,13 +2529,12 @@ class GraphContext implements Context {
|
||||
// for tests we have set the above ENV's to minimum which is 1 sec as we check the details for the deleted users
|
||||
sleep(1);
|
||||
}
|
||||
$response = GraphHelper::getSharesSharedByMe(
|
||||
return GraphHelper::getSharesSharedByMe(
|
||||
$this->featureContext->getBaseUrl(),
|
||||
$this->featureContext->getStepLineRef(),
|
||||
$credentials['username'],
|
||||
$credentials['password']
|
||||
);
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2547,7 +2546,8 @@ class GraphContext implements Context {
|
||||
* @throws GuzzleException
|
||||
*/
|
||||
public function userListsTheResourcesSharedByAUserUsingGraphApi(string $user): void {
|
||||
$this->listSharesSharedByMe($user);
|
||||
$response = $this->listSharesSharedByMe($user);
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2559,7 +2559,8 @@ class GraphContext implements Context {
|
||||
* @throws GuzzleException
|
||||
*/
|
||||
public function userListsTheResourcesSharedByAUserAfterClearingUserOrGroupSpaceUsingGraphApi(string $user): void {
|
||||
$this->listSharesSharedByMe($user, true);
|
||||
$response = $this->listSharesSharedByMe($user, true);
|
||||
$this->featureContext->setResponse($response);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user