From 1c073d3a0cf593da1dffc2dbee4c91342695d574 Mon Sep 17 00:00:00 2001 From: Sysix Date: Sat, 13 Apr 2024 17:44:07 +0200 Subject: [PATCH] add tests for new contact filters --- tests/Clients/ContactTest.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/Clients/ContactTest.php b/tests/Clients/ContactTest.php index c9fc7c6..48bf574 100644 --- a/tests/Clients/ContactTest.php +++ b/tests/Clients/ContactTest.php @@ -29,6 +29,8 @@ public function testGetPageWithFilters(): void { [$api, $client] = $this->createClientMockObject(Contact::class); + $client->email = 'john.doe@example.com'; + $client->name = 'John Doe'; $client->number = 12345; $client->customer = true; $client->vendor = false; @@ -36,7 +38,7 @@ public function testGetPageWithFilters(): void $client->getPage(0); $this->assertEquals( - $api->apiUrl . '/v1/contacts?page=0&number=12345&customer=1&vendor=0&size=100', + $api->apiUrl . '/v1/contacts?page=0&email=john.doe%40example.com&name=John+Doe&number=12345&customer=1&vendor=0&size=100', $api->getRequest()->getUri()->__toString() ); }