diff --git a/tests/integration/PHPUnit/VaultingSubscriptionsTest.php b/tests/integration/PHPUnit/VaultingSubscriptionsTest.php index 72e35e54f..54acc4de8 100644 --- a/tests/integration/PHPUnit/VaultingSubscriptionsTest.php +++ b/tests/integration/PHPUnit/VaultingSubscriptionsTest.php @@ -97,8 +97,8 @@ class VaultingSubscriptionsTest extends IntegrationMockedTestCase add_filter('user_has_cap', $user_has_cap_callback, 10, 3); // Convert to Mockery mocks - $billing_agreements_endpoint_mock = \Mockery::mock(ReferenceTransactionStatus::class); - $billing_agreements_endpoint_mock->shouldReceive('reference_transaction_enabled') + $reference_transaction_status = \Mockery::mock(ReferenceTransactionStatus::class); + $reference_transaction_status->shouldReceive('reference_transaction_enabled') ->andReturn(true); $state_mock = \Mockery::mock(State::class); @@ -115,8 +115,8 @@ class VaultingSubscriptionsTest extends IntegrationMockedTestCase // Create and configure the SettingsListener $c = $this->bootstrapModule([ - 'api.endpoint.billing-agreements' => function () use ($billing_agreements_endpoint_mock) { - return $billing_agreements_endpoint_mock; + 'api.endpoint.billing-agreements' => function () use ($reference_transaction_status) { + return $reference_transaction_status; }, 'onboarding.state' => function () use ($state_mock) { return $state_mock;