From f46e16282ffdb2aeaa5a67a84cbbed05a5d101a9 Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Wed, 18 Oct 2023 01:03:57 +0000 Subject: [PATCH] add invalid api function tests --- tests/Controller/ApiControllerTest.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/Controller/ApiControllerTest.php b/tests/Controller/ApiControllerTest.php index 2cf1f4e..23eae7f 100755 --- a/tests/Controller/ApiControllerTest.php +++ b/tests/Controller/ApiControllerTest.php @@ -276,4 +276,14 @@ final class ApiControllerTest extends \PHPUnit\Framework\TestCase $this->module->apiExchangeExport($request, $response); self::assertEquals(RequestStatusCode::R_400, $response->header->status); } + + public function testInvalidapiExchangeSettingCreate() : void + { + $response = new HttpResponse(); + $request = new HttpRequest(new HttpUri('')); + + $request->header->account = 1; + $this->module->apiExchangeSettingCreate($request, $response); + self::assertEquals(RequestStatusCode::R_400, $response->header->status); + } }