Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sunaoka committed Aug 6, 2024
1 parent 24d291b commit e7d3f97
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/ClientTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ public function test_http_with_options(): void
{
$options = [
RequestOptions::PROXY => 'http://localhost:8125',
RequestOptions::CONNECT_TIMEOUT => 3.14,
];
$client = new Client([
'API_KEY' => 'api_key',
Expand All @@ -144,6 +145,7 @@ public function test_http_with_options(): void
$config = $property->getValue($http);

self::assertIsArray($config);
self::assertSame($options[RequestOptions::PROXY], $config['proxy']);
self::assertSame($options[RequestOptions::PROXY], $config[RequestOptions::PROXY]);
self::assertSame($options[RequestOptions::CONNECT_TIMEOUT], $config[RequestOptions::CONNECT_TIMEOUT]);
}
}

0 comments on commit e7d3f97

Please sign in to comment.