From d7a2d3159754bcf0dbba538d60c3b135ff144d8a Mon Sep 17 00:00:00 2001 From: eileen Date: Sat, 16 Mar 2019 09:36:34 +1300 Subject: [PATCH] Attempt to fix test with 1 second delay (note in 'real life' the events are not generally so close together --- tests/phpunit/api/v3/LoggingTest.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/phpunit/api/v3/LoggingTest.php b/tests/phpunit/api/v3/LoggingTest.php index 4b2a9faf44..f79a274581 100644 --- a/tests/phpunit/api/v3/LoggingTest.php +++ b/tests/phpunit/api/v3/LoggingTest.php @@ -412,6 +412,9 @@ class api_v3_LoggingTest extends CiviUnitTestCase { $contactId = $this->individualCreate(); $this->callAPISuccess('Setting', 'create', array('logging' => TRUE)); CRM_Core_DAO::executeQuery("SET @uniqueID = 'wooty wop wop'"); + // Perhaps if initialize & create are exactly the same time it can't cope. + // 1 second delay + sleep(1); $this->callAPISuccess('Contact', 'create', array( 'id' => $contactId, 'first_name' => 'Dopey', -- 2.25.1