From 411fabb1f5c6b300bbe700af3bc30e9bede4b0d2 Mon Sep 17 00:00:00 2001 From: Konstantin Grachev Date: Wed, 9 Jun 2021 18:20:46 +0300 Subject: [PATCH] Fix: get default settings from real object --- tests/ClientConfigTest.php | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/tests/ClientConfigTest.php b/tests/ClientConfigTest.php index 54eb1bc..7592cb7 100644 --- a/tests/ClientConfigTest.php +++ b/tests/ClientConfigTest.php @@ -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];