@@ -92,7 +92,7 @@ public function testMoreExecutesWithoutCompletePrevious(): void
9292 {
9393 Tester \Assert::exception (function (): void {
9494 $ this ->connection ->asyncExecute ('SELECT 1 ' )->asyncExecute ('SELECT 2 ' );
95- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
95+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
9696 }
9797
9898
@@ -101,7 +101,7 @@ public function testCompleteExecuteWithQuery(): void
101101 Tester \Assert::exception (function (): void {
102102 $ this ->connection ->asyncQuery ('SELECT 1 ' );
103103 $ this ->connection ->completeAsyncExecute ();
104- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_NO_EXECUTE_IS_SENT );
104+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_NO_EXECUTE_IS_SENT );
105105 }
106106
107107
@@ -112,7 +112,7 @@ public function testGetQueryResultAfterExecute(): void
112112 Tester \Assert::exception (function () use ($ asyncQuery ): void {
113113 $ this ->connection ->asyncExecute ('SELECT 2 ' );
114114 $ asyncQuery ->getNextResult ();
115- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
115+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
116116 }
117117
118118
@@ -124,7 +124,7 @@ public function testCancelAsyncQuery(): void
124124
125125 Tester \Assert::exception (static function () use ($ asyncQuery ): void {
126126 $ asyncQuery ->getNextResult ();
127- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_NO_QUERY_IS_SENT );
127+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_NO_QUERY_IS_SENT );
128128 }
129129
130130
@@ -146,7 +146,7 @@ public function testMoreAsyncQueriesWithoutCompletePrevious(): void
146146
147147 Tester \Assert::exception (function (): void {
148148 $ this ->connection ->asyncQuery ('SELECT 2 ' );
149- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
149+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_QUERY_SENT_FAILED );
150150 }
151151
152152
@@ -162,13 +162,13 @@ public function testMoreAsyncQueriesInOne(): void
162162
163163 Tester \Assert::exception (static function () use ($ asyncQuery1 ): void {
164164 $ asyncQuery1 ->getNextResult ();
165- }, Db \Exceptions \ResultException::class, null , Db \Exceptions \ResultException::NO_OTHER_ASYNC_RESULT );
165+ }, Db \Exceptions \ResultException::class, code: Db \Exceptions \ResultException::NO_OTHER_ASYNC_RESULT );
166166
167167 $ asyncQuery2 = $ this ->connection ->asyncQuery ('SELECT 3 ' );
168168
169169 Tester \Assert::exception (static function () use ($ asyncQuery1 ): void {
170170 $ asyncQuery1 ->getNextResult ();
171- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_ANOTHER_QUERY_IS_RUNNING );
171+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_ANOTHER_QUERY_IS_RUNNING );
172172
173173 $ result3 = $ asyncQuery2 ->getNextResult ();
174174 Tester \Assert::same (3 , $ result3 ->fetchSingle ());
@@ -177,7 +177,7 @@ public function testMoreAsyncQueriesInOne(): void
177177
178178 Tester \Assert::exception (static function () use ($ asyncQuery1 ): void {
179179 $ asyncQuery1 ->getNextResult ();
180- }, Db \Exceptions \ConnectionException::class, null , Db \Exceptions \ConnectionException::ASYNC_ANOTHER_QUERY_IS_RUNNING );
180+ }, Db \Exceptions \ConnectionException::class, code: Db \Exceptions \ConnectionException::ASYNC_ANOTHER_QUERY_IS_RUNNING );
181181 }
182182
183183
@@ -196,12 +196,12 @@ public function testError(): void
196196 $ asyncQuery = $ this ->connection ->asyncQuery ('SELECT bad_column ' );
197197 Tester \Assert::exception (static function () use ($ asyncQuery ): void {
198198 $ asyncQuery ->getNextResult ();
199- }, Db \Exceptions \QueryException::class, null , Db \Exceptions \QueryException::ASYNC_QUERY_FAILED );
199+ }, Db \Exceptions \QueryException::class, code: Db \Exceptions \QueryException::ASYNC_QUERY_FAILED );
200200
201201 $ this ->connection ->asyncExecute ('SELECT bad_column ' );
202202 Tester \Assert::exception (function (): void {
203203 $ this ->connection ->completeAsyncExecute ();
204- }, Db \Exceptions \QueryException::class, null , Db \Exceptions \QueryException::ASYNC_QUERY_FAILED );
204+ }, Db \Exceptions \QueryException::class, code: Db \Exceptions \QueryException::ASYNC_QUERY_FAILED );
205205 }
206206
207207
0 commit comments