From 5b470de74f4a2d70e2bcd624f4a0d4c9ec0d3005 Mon Sep 17 00:00:00 2001 From: MDW Date: Fri, 15 Mar 2024 13:04:43 +0100 Subject: [PATCH] Qual: Improve test message on failure --- test/phpunit/RestAPIContactTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/phpunit/RestAPIContactTest.php b/test/phpunit/RestAPIContactTest.php index 4af37c718e078..dd4173ab6ffb7 100644 --- a/test/phpunit/RestAPIContactTest.php +++ b/test/phpunit/RestAPIContactTest.php @@ -1,6 +1,7 @@ * Copyright (C) 2023 Alexandre Janniaux + * Copyright (C) 2024 MDW * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -229,7 +230,7 @@ public function testRestUpdateContact($objid) print_r($updateResponse); // Check if the updated fields match the changes you made - $this->assertTrue($updateResponse['firstname'] === $updateBody['firstname'], 'Update might have failed'); + $this->assertEquals($updateBody['firstname'], $updateResponse['firstname'], 'Update failed for request body: '.$updateRequestBody); // Deleting the Contact /*