Skip to content

Commit 61fa08e

Browse files
committed
fix(php): waitForApiKey consistency
1 parent 6f1d30e commit 61fa08e

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

templates/php/api.mustache

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -362,8 +362,8 @@ use {{invokerPackage}}\Support\Helpers;
362362
/**
363363
* Wait for an API key to be added, updated or deleted based on a given `operation`.
364364
*
365-
* @param string $operation the `operation` that was done on a `key`
366365
* @param string $key the `key` that has been added, deleted or updated
366+
* @param string $operation the `operation` that was done on a `key`
367367
* @param array $apiKey Necessary to know if an `update` operation has been processed, compare fields of the response with it.
368368
* @param int|null $maxRetries Maximum number of retries
369369
* @param int|null $timeout Timeout
@@ -374,8 +374,8 @@ use {{invokerPackage}}\Support\Helpers;
374374
* @return void
375375
*/
376376
public function waitForApiKey(
377-
$operation,
378377
$key,
378+
$operation,
379379
$apiKey = null,
380380
$maxRetries = null,
381381
$timeout = null,

templates/php/tests/client/suite.mustache

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,10 +102,15 @@ class {{clientPrefix}}Test extends TestCase implements HttpClientInterface
102102
);
103103
{{/matchIsJSON}}
104104
{{^matchIsJSON}}
105-
$this->assertEquals(
106-
'{{{match}}}',
107-
$res
108-
);
105+
{{#matchIsNull}}
106+
$this->assertNull($res);
107+
{{/matchIsNull}}
108+
{{^matchIsNull}}
109+
$this->assertEquals(
110+
'{{{match}}}',
111+
$res
112+
);
113+
{{/matchIsNull}}
109114
{{/matchIsJSON}}
110115
{{/testResponse}}
111116
{{/match}}

0 commit comments

Comments
 (0)