From fb65d7a965d0dc263fa7c28f8709bb9f6b0522ca Mon Sep 17 00:00:00 2001 From: Jake Barnby Date: Tue, 16 Sep 2025 13:25:15 +1200 Subject: [PATCH] Add scoped tests --- .../{TransactionsTest.php => TransactionsBase.php} | 8 +------- .../Transactions/TransactionsConsoleClientTest.php | 13 +++++++++++++ .../Transactions/TransactionsCustomClientTest.php | 13 +++++++++++++ .../Transactions/TransactionsCustomServerTest.php | 13 +++++++++++++ .../{TransactionsTest.php => TransactionsBase.php} | 8 +------- .../Transactions/TransactionsConsoleClientTest.php | 13 +++++++++++++ .../Transactions/TransactionsCustomClientTest.php | 13 +++++++++++++ .../Transactions/TransactionsCustomServerTest.php | 13 +++++++++++++ 8 files changed, 80 insertions(+), 14 deletions(-) rename tests/e2e/Services/Databases/Legacy/Transactions/{TransactionsTest.php => TransactionsBase.php} (99%) create mode 100644 tests/e2e/Services/Databases/Legacy/Transactions/TransactionsConsoleClientTest.php create mode 100644 tests/e2e/Services/Databases/Legacy/Transactions/TransactionsCustomClientTest.php create mode 100644 tests/e2e/Services/Databases/Legacy/Transactions/TransactionsCustomServerTest.php rename tests/e2e/Services/Databases/TablesDB/Transactions/{TransactionsTest.php => TransactionsBase.php} (99%) create mode 100644 tests/e2e/Services/Databases/TablesDB/Transactions/TransactionsConsoleClientTest.php create mode 100644 tests/e2e/Services/Databases/TablesDB/Transactions/TransactionsCustomClientTest.php create mode 100644 tests/e2e/Services/Databases/TablesDB/Transactions/TransactionsCustomServerTest.php diff --git a/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsTest.php b/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsBase.php similarity index 99% rename from tests/e2e/Services/Databases/Legacy/Transactions/TransactionsTest.php rename to tests/e2e/Services/Databases/Legacy/Transactions/TransactionsBase.php index a76d909b5e..f05563123c 100644 --- a/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsTest.php +++ b/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsBase.php @@ -3,19 +3,13 @@ namespace Tests\E2E\Services\Databases\Legacy\Transactions; use Tests\E2E\Client; -use Tests\E2E\Scopes\ProjectCustom; -use Tests\E2E\Scopes\Scope; -use Tests\E2E\Scopes\SideClient; use Utopia\Database\Helpers\ID; use Utopia\Database\Helpers\Permission; use Utopia\Database\Helpers\Role; use Utopia\Database\Query; -class TransactionsTest extends Scope +trait TransactionsBase { - use ProjectCustom; - use SideClient; - /** * Test creating a transaction */ diff --git a/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsConsoleClientTest.php b/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsConsoleClientTest.php new file mode 100644 index 0000000000..427e79fb3a --- /dev/null +++ b/tests/e2e/Services/Databases/Legacy/Transactions/TransactionsConsoleClientTest.php @@ -0,0 +1,13 @@ +