diff --git a/tests/phpunit/api/v3/OrderTest.php b/tests/phpunit/api/v3/OrderTest.php index 68511e9ac73b..58ab4f7d2a81 100644 --- a/tests/phpunit/api/v3/OrderTest.php +++ b/tests/phpunit/api/v3/OrderTest.php @@ -339,6 +339,16 @@ public function testAddOrderForParticipant() { 'id' => $order['id'], ]); + // Enable the "Pending from approval" status which is not enabled by default + $pendingFromApprovalParticipantStatus = civicrm_api3('ParticipantStatusType', 'getsingle', [ + 'name' => "Pending from approval", + ]); + civicrm_api3('ParticipantStatusType', 'create', [ + 'id' => $pendingFromApprovalParticipantStatus['id'], + 'name' => "Pending from approval", + 'is_active' => 1, + ]); + $p['line_items'][] = [ 'line_item' => $lineItems, 'params' => [