From 6dc163e38f2021ead2a538ac64e21617a14acb5e Mon Sep 17 00:00:00 2001 From: Adam Kelso Date: Sat, 17 Feb 2024 15:09:58 -0700 Subject: [PATCH] Fix namespaces --- src/Filters/WithJson.php | 1 - src/Filters/WithRpc.php | 1 - src/Helpers/macros.php | 27 --------------------------- tests/ExceptionMessageRegex.php | 2 +- tests/Filters/WithEndpointTest.php | 2 +- tests/Filters/WithFileTest.php | 2 +- tests/Filters/WithFormTest.php | 2 +- tests/Filters/WithHeaderTest.php | 2 +- tests/Filters/WithJsonTest.php | 2 +- tests/Filters/WithOptionTest.php | 2 +- tests/Filters/WithQueryTest.php | 2 +- tests/Filters/WithRpcTest.php | 2 +- tests/Filters/WithVersionTest.php | 2 +- tests/GuzzlerTest.php | 2 +- 14 files changed, 11 insertions(+), 40 deletions(-) delete mode 100755 src/Helpers/macros.php diff --git a/src/Filters/WithJson.php b/src/Filters/WithJson.php index de5ad32..853f1bc 100755 --- a/src/Filters/WithJson.php +++ b/src/Filters/WithJson.php @@ -8,7 +8,6 @@ class WithJson extends Base implements With { - use RecursiveSort; /** @var string */ diff --git a/src/Filters/WithRpc.php b/src/Filters/WithRpc.php index fb20f6f..9ee87a4 100755 --- a/src/Filters/WithRpc.php +++ b/src/Filters/WithRpc.php @@ -11,7 +11,6 @@ class WithRpc extends Base implements With { - use RecursiveSort; const JSON_RPC_VERSION = '2.0'; diff --git a/src/Helpers/macros.php b/src/Helpers/macros.php deleted file mode 100755 index 34b3dd6..0000000 --- a/src/Helpers/macros.php +++ /dev/null @@ -1,27 +0,0 @@ -withOption('synchronous', true); -}); - -Expectation::macro('asynchronous', function (BlastCloud\Chassis\Expectation $e) { - // Set to null, because if the request was asynchronous, the - // "synchronous" key is not set in the options array. - return $e->withOption('synchronous', null); -}); - -foreach (Expectation::VERBS as $verb) { // @codeCoverageIgnore - Expectation::macro($verb, function (BlastCloud\Chassis\Expectation $e, $uri) use ($verb) { - return $e->withEndpoint($uri, strtoupper($verb)); - }); -} - -Expectation::macro('endpoint', function (BlastCloud\Chassis\Expectation $e, $url, $method) { - return $e->withEndpoint($url, strtoupper($method)); -}); - -Expectation::macro('withoutQuery', function (BlastCloud\Chassis\Expectation $e) { - return $e->withQuery([], true); -}); \ No newline at end of file diff --git a/tests/ExceptionMessageRegex.php b/tests/ExceptionMessageRegex.php index 1658b10..a3871bf 100755 --- a/tests/ExceptionMessageRegex.php +++ b/tests/ExceptionMessageRegex.php @@ -1,6 +1,6 @@