From f7f5f4223d9b341cafae61631fdd1dd5cd16c26f Mon Sep 17 00:00:00 2001 From: KarunAtreya Date: Mon, 25 Sep 2023 10:10:14 +0545 Subject: [PATCH] reset after scenario using after hook --- tests/acceptance/features/bootstrap/FeatureContext.php | 1 + tests/acceptance/features/bootstrap/TUSContext.php | 6 ------ 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/tests/acceptance/features/bootstrap/FeatureContext.php b/tests/acceptance/features/bootstrap/FeatureContext.php index e7903b1a952..b437bda4ceb 100644 --- a/tests/acceptance/features/bootstrap/FeatureContext.php +++ b/tests/acceptance/features/bootstrap/FeatureContext.php @@ -3391,6 +3391,7 @@ public function clearSpaceId(): void { if (\count(WebDavHelper::$spacesIdRef) > 0) { WebDavHelper::$spacesIdRef = []; } + WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** diff --git a/tests/acceptance/features/bootstrap/TUSContext.php b/tests/acceptance/features/bootstrap/TUSContext.php index 9aede101399..57b912d3bb1 100644 --- a/tests/acceptance/features/bootstrap/TUSContext.php +++ b/tests/acceptance/features/bootstrap/TUSContext.php @@ -156,7 +156,6 @@ public function sendsAChunkToTUSLocationWithOffsetAndData(string $user, string $ public function userSendsAChunkToTUSLocationWithOffsetAndData(string $user, string $offset, string $data): void { $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $data); $this->featureContext->setResponse($response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** @@ -438,7 +437,6 @@ public function userUploadsFileWithChecksum( ): void { $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $content, $checksum); $this->featureContext->setResponse($response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** @@ -460,7 +458,6 @@ public function userHasUploadedFileWithChecksum( ): void { $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $content, $checksum); $this->featureContext->theHTTPStatusCodeShouldBe(204, "", $response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** @@ -477,7 +474,6 @@ public function userHasUploadedFileWithChecksum( public function userUploadsChunkFileWithChecksum(string $user, string $offset, string $data, string $checksum): void { $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $data, $checksum); $this->featureContext->setResponse($response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** @@ -494,7 +490,6 @@ public function userUploadsChunkFileWithChecksum(string $user, string $offset, s public function userHasUploadedChunkFileWithChecksum(string $user, string $offset, string $data, string $checksum): void { $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $data, $checksum); $this->featureContext->theHTTPStatusCodeShouldBe(204, "", $response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } /** @@ -516,6 +511,5 @@ public function userOverwritesFileWithChecksum(string $user, string $offset, str $this->userHasCreatedNewTUSResourceWithHeaders($user, $headers); $response = $this->sendsAChunkToTUSLocationWithOffsetAndData($user, $offset, $data, $checksum); $this->featureContext->setResponse($response); - WebDavHelper::$SPACE_ID_FROM_OCIS = ''; } }