Fix: get default settings from real object

This commit is contained in:
2021-06-09 18:20:46 +03:00
parent 34847e2467
commit 411fabb1f5

View File

@ -25,23 +25,7 @@ final class ClientConfigTest extends TestCase
public function array(): Generator
{
$default = [
'authSecret' => null,
'connectTimeout' => 10,
'maxAttempts' => 0,
'tcpNoDelay' => false,
'featureNegotiation' => true,
'clientId' => '',
'deflate' => false,
'deflateLevel' => 6,
'heartbeatInterval' => 30000,
'hostname' => gethostname(),
'msgTimeout' => 60000,
'sampleRate' => 0,
'tls' => false,
'snappy' => false,
'userAgent' => 'nsqphp/dev-main',
];
$default = get_object_vars(new ClientConfig());
yield 'Empty array' => [[], $default];