diff --git a/test/Billing.Test/Services/StripeEventServiceTests.cs b/test/Billing.Test/Services/StripeEventServiceTests.cs index f2fe1c8d19..1e4d6c2641 100644 --- a/test/Billing.Test/Services/StripeEventServiceTests.cs +++ b/test/Billing.Test/Services/StripeEventServiceTests.cs @@ -466,12 +466,10 @@ public class StripeEventServiceTests var customer = await GetCustomerAsync(); - invoice.Customer = customer; - - _stripeFacade.GetInvoice( - invoice.Id, - Arg.Any()) - .Returns(invoice); + _stripeFacade.GetCustomer( + invoice.CustomerId, + Arg.Any()) + .Returns(customer); // Act var cloudRegionValid = await _stripeEventService.ValidateCloudRegion(stripeEvent); @@ -479,9 +477,9 @@ public class StripeEventServiceTests // Assert cloudRegionValid.Should().BeTrue(); - await _stripeFacade.Received(1).GetInvoice( - invoice.Id, - Arg.Any(), + await _stripeFacade.Received(1).GetCustomer( + invoice.CustomerId, + Arg.Any(), Arg.Any(), Arg.Any()); }