티스토리 수익 글 보기
*/
private $searchParams;
protected function setUp(): void
{
parent::setUp();
$this->searchParams = [
‘engine’ => ‘walmart’,
‘query’ => ‘coffee’,
];
}
public function testResultExists()
{
$client = $this->serpApiClient();
$response = $client->search($this->searchParams);
$this->assertResponseHasProperty($response, ‘organic_results’, ‘Error on `walmart` engine: no `organic_results`’);
}
}