Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
NachoSoto committed Jan 31, 2024
1 parent b4a44d2 commit 0b68b52
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Tests/RevenueCatUITests/PaywallFooterTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ class PaywallFooterTests: TestCase {

Task {
_ = try await Self.purchaseHandler.restorePurchases()
// Simulates what `RestorePurchasesButton` does after dismissing the alert.
Self.purchaseHandler.setRestored(TestData.customerInfo)
}

expect(customerInfo).toEventually(be(TestData.customerInfo))
Expand Down
2 changes: 2 additions & 0 deletions Tests/RevenueCatUITests/PresentIfNeededTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ class PresentIfNeededTests: TestCase {

Task {
_ = try await Self.purchaseHandler.restorePurchases()
// Simulates what `RestorePurchasesButton` does after dismissing the alert.
Self.purchaseHandler.setRestored(TestData.customerInfo)
}

expect(customerInfo).toEventually(be(TestData.customerInfo))
Expand Down

0 comments on commit 0b68b52

Please sign in to comment.