diff --git a/tests/acceptance/features/apiSpaces/quota.feature b/tests/acceptance/features/apiSpaces/quota.feature index 1358811686..bf67676ca0 100644 --- a/tests/acceptance/features/apiSpaces/quota.feature +++ b/tests/acceptance/features/apiSpaces/quota.feature @@ -130,3 +130,12 @@ Feature: State of the quota And user "Brian" has been created with default attributes and without skeleton files When user "Brian" uploads file with content "more than 10 bytes content" to "lorem.txt" using the WebDAV API Then the HTTP status code should be "507" + + @env-config + Scenario: try to create a space with quota greater than OCIS spaces max quota + Given the config "OCIS_SPACES_MAX_QUOTA" has been set to "50" + And user "Brian" has been created with default attributes and without skeleton files + And the administrator has given "Brian" the role "Space Admin" using the settings api + When user "Brian" tries to create a space "new space" of type "project" with quota "51" using the Graph API + Then the HTTP status code should be "400" + And the user "Brian" should not have a space called "new space" diff --git a/tests/acceptance/features/bootstrap/SpacesContext.php b/tests/acceptance/features/bootstrap/SpacesContext.php index 2d6acc28d3..093237fa10 100644 --- a/tests/acceptance/features/bootstrap/SpacesContext.php +++ b/tests/acceptance/features/bootstrap/SpacesContext.php @@ -603,6 +603,7 @@ class SpacesContext implements Context { /** * @When /^user "([^"]*)" creates a space "([^"]*)" of type "([^"]*)" with quota "([^"]*)" using the Graph API$/ + * @When /^user "([^"]*)" tries to create a space "([^"]*)" of type "([^"]*)" with quota "([^"]*)" using the Graph API$/ * * @param string $user * @param string $spaceName