diff --git a/.drone.star b/.drone.star index 11a07a34b2a..59a89178478 100644 --- a/.drone.star +++ b/.drone.star @@ -135,6 +135,7 @@ config = { "apiSpaces", ], "skip": False, + "k8s": True, }, "spacesShares": { "suites": [ diff --git a/tests/acceptance/bootstrap/OcisConfigContext.php b/tests/acceptance/bootstrap/OcisConfigContext.php index 69d1c91013c..fb4893c2edb 100644 --- a/tests/acceptance/bootstrap/OcisConfigContext.php +++ b/tests/acceptance/bootstrap/OcisConfigContext.php @@ -318,6 +318,7 @@ public function theAdministratorHasStartedServiceSeparatelyWithTheFollowingConfi */ public function rollback(): void { if (\getenv('K8S') === "true") { + $this->rollbackK8sServices(); return; } $this->rollbackServices(); @@ -349,4 +350,18 @@ public function rollbackServices(): void { "Failed to rollback services.", ); } + + /** + * @return void + * @throws GuzzleException + */ + public function rollbackK8sServices(): void { + $url = OcisConfigHelper::getWrapperUrl() . "/k8s/rollback"; + $response = OcisConfigHelper::sendRequest($url, "DELETE"); + Assert::assertEquals( + 200, + $response->getStatusCode(), + "Failed to rollback services.", + ); + } } diff --git a/tests/acceptance/features/apiSpaces/quota.feature b/tests/acceptance/features/apiSpaces/quota.feature index 160414f9722..55ab397ff91 100644 --- a/tests/acceptance/features/apiSpaces/quota.feature +++ b/tests/acceptance/features/apiSpaces/quota.feature @@ -122,14 +122,14 @@ Feature: State of the quota @env-config Scenario: upload a file by setting OCIS spaces max quota - Given the config "OCIS_SPACES_MAX_QUOTA" has been set to "10" for "storageusers" service + Given the config "STORAGE_USERS_OCIS_MAX_QUOTA" has been set to "10" for "storageusers" service And user "Brian" has been created with default attributes 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" for "storageusers" service + Given the config "STORAGE_USERS_OCIS_MAX_QUOTA" has been set to "50" for "storageusers" service And user "Brian" has been created with default attributes And the administrator has assigned the role "Space Admin" to user "Brian" using the Graph API When user "Brian" tries to create a space "new space" of type "project" with quota "51" using the Graph API diff --git a/tests/config/drone/k3s/values.yaml b/tests/config/drone/k3s/values.yaml index db6025a34f8..c898803ef8e 100644 --- a/tests/config/drone/k3s/values.yaml +++ b/tests/config/drone/k3s/values.yaml @@ -30,6 +30,9 @@ features: - "12345678" - "ownCloud" - "owncloud-1" + quotas: + default: "1000000000" + max: "0" http: cors: