From 8cc4d735f59e7ea5515dc27e5a3774e23a7d7dfa Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Thu, 8 Jun 2023 08:06:51 +1200 Subject: [PATCH] Use APIv4 when creating test entities --- tests/phpunit/CiviTest/CiviUnitTestCase.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/phpunit/CiviTest/CiviUnitTestCase.php b/tests/phpunit/CiviTest/CiviUnitTestCase.php index 82a4451df8..5e4756e3bb 100644 --- a/tests/phpunit/CiviTest/CiviUnitTestCase.php +++ b/tests/phpunit/CiviTest/CiviUnitTestCase.php @@ -569,6 +569,7 @@ class CiviUnitTestCase extends PHPUnit\Framework\TestCase { * @return array|int */ protected function createTestEntity(string $entity, array $params, string $identifier = 'default') { + $params['version'] = 4; $result = $this->callAPISuccess($entity, 'create', $params); $this->setTestEntityID($entity, $result['id'], $identifier); return reset($result['values']); -- 2.25.1