From e8b13f27f5d8f83c8b5026841a65e45daf53c4e1 Mon Sep 17 00:00:00 2001 From: Sebastian Molenda Date: Tue, 18 Jun 2024 13:56:26 +0200 Subject: [PATCH] Order the test dependencies --- tests/integrational/FilesTest.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/integrational/FilesTest.php b/tests/integrational/FilesTest.php index 8e615e3d..83d764fb 100644 --- a/tests/integrational/FilesTest.php +++ b/tests/integrational/FilesTest.php @@ -2,6 +2,7 @@ namespace PubNubTests\integrational; +use PHPUnit\Framework\Attributes\Depends; use PubNubTestCase; class FilesTest extends PubNubTestCase @@ -19,6 +20,7 @@ public function testEmptyFileList() $this->assertCount(0, $response->getData()); } + #[Depends('testEmptyFileList')] public function testSendTextFile() { $file = fopen($this->textFilePath, "r"); @@ -34,6 +36,7 @@ public function testSendTextFile() $this->assertNotEmpty($response->getTimestamp()); } + #[Depends('testEmptyFileList')] public function testSendBinaryFile() { $file = fopen($this->binaryFilePath, "r"); @@ -49,6 +52,8 @@ public function testSendBinaryFile() $this->assertNotEmpty($response->getTimestamp()); } + #[Depends('testSendTextFile')] + #[Depends('testSendBinaryFile')] public function testNonEmptyFileList() { $response = $this->pubnub->listFiles()->channel($this->channel)->sync(); @@ -57,6 +62,7 @@ public function testNonEmptyFileList() $this->textFileId = $response->getData()[0]['id']; } + #[Depends('testNonEmptyFileList')] public function testGetDownloadUrls() { $listFilesResponse = $this->pubnub->listFiles()->channel($this->channel)->sync(); @@ -71,6 +77,7 @@ public function testGetDownloadUrls() } } + #[Depends('testGetDownloadUrls')] public function testDownloadFiles() { $listFilesResponse = $this->pubnub->listFiles()->channel($this->channel)->sync(); @@ -89,6 +96,7 @@ public function testDownloadFiles() } } + #[Depends('testDownloadFiles')] public function testDeleteAllFiles() { $listFilesResponse = $this->pubnub->listFiles()->channel($this->channel)->sync();