Test fix
authoreileen <emcnaughton@wikimedia.org>
Wed, 3 Apr 2019 22:20:51 +0000 (11:20 +1300)
committereileen <emcnaughton@wikimedia.org>
Wed, 3 Apr 2019 22:20:51 +0000 (11:20 +1300)
tests/phpunit/api/v3/LoggingTest.php

index 8fad24a084b95b79cbdadf21ef396f8cfaa87074..23ff335dab7819cace929a669c7b986179680520 100644 (file)
@@ -414,6 +414,8 @@ class api_v3_LoggingTest extends CiviUnitTestCase {
     $contactId = $this->individualCreate();
     $this->callAPISuccess('Setting', 'create', array('logging' => TRUE));
     CRM_Core_DAO::executeQuery("SET @uniqueID = 'wooty woot'");
+    // Add delay so the update is actually enough after the create that the timestamps differ
+    sleep(1);
     $timeStamp = date('Y-m-d H:i:s');
     $this->callAPISuccess('Contact', 'create', array(
         'id' => $contactId,