diff --git a/tests/Resources/AffiliateCreatorTest.php b/tests/Resources/AffiliateCreatorTest.php index c181a95..70c5417 100644 --- a/tests/Resources/AffiliateCreatorTest.php +++ b/tests/Resources/AffiliateCreatorTest.php @@ -19,14 +19,6 @@ class AffiliateCreatorTest extends TestResource { public const TEST_API_VERSION = 202405; - protected function tiktokShopClientForTest() - { - $client = parent::tiktokShopClientForTest(); - $client->useVersion(self::TEST_API_VERSION); - - return $client; - } - public function testAddShowcaseProducts() { $this->caller->addShowcaseProducts('add_type', [1, 2, 3], 'product_link'); diff --git a/tests/Resources/AffiliateSellerTest.php b/tests/Resources/AffiliateSellerTest.php index d8e7b5d..062bbd1 100644 --- a/tests/Resources/AffiliateSellerTest.php +++ b/tests/Resources/AffiliateSellerTest.php @@ -20,14 +20,6 @@ class AffiliateSellerTest extends TestResource { public const TEST_API_VERSION = 202405; - protected function tiktokShopClientForTest() - { - $client = parent::tiktokShopClientForTest(); - $client->useVersion(self::TEST_API_VERSION); - - return $client; - } - public function testEditOpenCollaborationSettings() { $this->caller->editOpenCollaborationSettings([]); diff --git a/tests/TestResource.php b/tests/TestResource.php index 09edc4f..1b2967e 100644 --- a/tests/TestResource.php +++ b/tests/TestResource.php @@ -54,7 +54,10 @@ protected function setUp(): void protected function tiktokShopClientForTest() { - return new TiktokApiClient('app_key', 'app_secret'); + $client = new TiktokApiClient('app_key', 'app_secret'); + $client->useVersion(static::TEST_API_VERSION); + + return $client; } protected function assertPreviousRequest($method, $uri)