client = new Client(); $reflection = new \ReflectionClass($this->client); $devVersionsUrl = $reflection->getProperty('devVersionsUrl'); $devVersionsUrl->setAccessible(true); $devVersionsUrl->setValue($this->client, TEST_MOCKS_DIRECTORY . '/responses/dev-body.txt'); $stableVersionsUrl = $reflection->getProperty('stableVersionsUrl'); $stableVersionsUrl->setAccessible(true); $stableVersionsUrl->setValue($this->client, TEST_MOCKS_DIRECTORY . '/responses/stable-body.txt'); } public function testFetchDevVersions(): void { $this->assertIsArray($this->client->fetchDevVersions()); } public function testFetchStableVersions(): void { $this->assertIsArray($this->client->fetchStableVersions()); } }