diff --git a/build/integration/features/bootstrap/CapabilitiesContext.php b/build/integration/features/bootstrap/CapabilitiesContext.php index 83d5f5fd2f..0eb6353a89 100644 --- a/build/integration/features/bootstrap/CapabilitiesContext.php +++ b/build/integration/features/bootstrap/CapabilitiesContext.php @@ -15,8 +15,6 @@ require __DIR__ . '/../../vendor/autoload.php'; class CapabilitiesContext implements Context, SnippetAcceptingContext { use BasicStructure; - use Provisioning; - use Sharing; /** * @Given /^parameter "([^"]*)" of app "([^"]*)" is set to "([^"]*)"$/ diff --git a/build/integration/features/bootstrap/Provisioning.php b/build/integration/features/bootstrap/Provisioning.php index a3359ac96d..bf84058c05 100644 --- a/build/integration/features/bootstrap/Provisioning.php +++ b/build/integration/features/bootstrap/Provisioning.php @@ -1,16 +1,12 @@ baseUrl . "v2.php/cloud/users/$user/groups"; @@ -160,7 +160,6 @@ trait Provisioning { } $this->response = $client->get($fullUrl, $options); - $groups = array($group); $respondedArray = $this->getArrayOfGroupsResponded($this->response); if (array_key_exists($group, $respondedArray)) { @@ -172,6 +171,8 @@ trait Provisioning { /** * @Given /^user "([^"]*)" belongs to group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function assureUserBelongsToGroup($user, $group){ if (!$this->userBelongsToGroup($user, $group)){ @@ -186,6 +187,8 @@ trait Provisioning { /** * @Given /^user "([^"]*)" does not belong to group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function userDoesNotBelongToGroup($user, $group) { $fullUrl = $this->baseUrl . "v2.php/cloud/users/$user/groups"; @@ -202,8 +205,9 @@ trait Provisioning { PHPUnit_Framework_Assert::assertEquals(200, $this->response->getStatusCode()); } - /** + /** * @When /^creating the group "([^"]*)"$/ + * @param string $group */ public function creatingTheGroup($group) { $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/groups"; @@ -227,6 +231,7 @@ trait Provisioning { /** * @When /^Deleting the user "([^"]*)"$/ + * @param string $user */ public function deletingTheUser($user) { $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/users/$user"; @@ -241,6 +246,7 @@ trait Provisioning { /** * @When /^Deleting the group "([^"]*)"$/ + * @param string $group */ public function deletingTheGroup($group) { $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/groups/$group"; @@ -255,6 +261,8 @@ trait Provisioning { /** * @Given /^Add user "([^"]*)" to the group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function addUserToGroup($user, $group) { $this->userExists($user); @@ -265,6 +273,8 @@ trait Provisioning { /** * @When /^User "([^"]*)" is added to the group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function addingUserToGroup($user, $group) { $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/users/$user/groups"; @@ -293,6 +303,7 @@ trait Provisioning { /** * @Given /^group "([^"]*)" exists$/ + * @param string $group */ public function assureGroupExists($group) { try { @@ -309,6 +320,7 @@ trait Provisioning { /** * @Given /^group "([^"]*)" does not exist$/ + * @param string $group */ public function groupDoesNotExist($group) { try { @@ -332,6 +344,8 @@ trait Provisioning { /** * @Given /^user "([^"]*)" is subadmin of group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function userIsSubadminOfGroup($user, $group) { $fullUrl = $this->baseUrl . "v2.php/cloud/groups/$group/subadmins"; @@ -350,6 +364,8 @@ trait Provisioning { /** * @Given /^user "([^"]*)" is not a subadmin of group "([^"]*)"$/ + * @param string $user + * @param string $group */ public function userIsNotSubadminOfGroup($user, $group) { $fullUrl = $this->baseUrl . "v2.php/cloud/groups/$group/subadmins"; @@ -477,6 +493,7 @@ trait Provisioning { /** * @Given /^app "([^"]*)" is disabled$/ + * @param string $app */ public function appIsDisabled($app) { $fullUrl = $this->baseUrl . "v2.php/cloud/apps?filter=disabled"; @@ -494,6 +511,7 @@ trait Provisioning { /** * @Given /^app "([^"]*)" is enabled$/ + * @param string $app */ public function appIsEnabled($app) { $fullUrl = $this->baseUrl . "v2.php/cloud/apps?filter=enabled"; @@ -511,6 +529,8 @@ trait Provisioning { /** * @Given user :user has a quota of :quota + * @param string $user + * @param string $quota */ public function userHasAQuotaOf($user, $quota) { @@ -525,6 +545,7 @@ trait Provisioning { /** * @Given user :user has unlimited quota + * @param string $user */ public function userHasUnlimitedQuota($user) { diff --git a/build/integration/features/bootstrap/Sharing.php b/build/integration/features/bootstrap/Sharing.php index dede98157d..5932194d14 100644 --- a/build/integration/features/bootstrap/Sharing.php +++ b/build/integration/features/bootstrap/Sharing.php @@ -1,7 +1,5 @@ lastShareData->data[0]->id; + $share_id = (string) $this->lastShareData->data[0]->id; $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/apps/files_sharing/api/v{$this->sharingApiVersion}/shares/$share_id"; $client = new Client(); $options = []; @@ -133,7 +132,7 @@ trait Sharing{ * @param \Behat\Gherkin\Node\TableNode|null $body */ public function updatingLastShare($body) { - $share_id = $this->lastShareData->data[0]->id; + $share_id = (string) $this->lastShareData->data[0]->id; $fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/apps/files_sharing/api/v{$this->sharingApiVersion}/shares/$share_id"; $client = new Client(); $options = [];