mirror of
https://github.com/RevenueCat/purchases-ios
synced 2026-11-11 22:55:55 +05:45
* Rename Test Store to Simulated Store only internally * fix lint * fix test under `SIMULATED_STORE` compiler flag * fix test compilation * Add name clarification to `APIKeyValidationResult.simulatedStore` enum case * Fix public-facing strings * Improve comment * improve comment
33 lines
764 B
Swift
33 lines
764 B
Swift
//
|
|
// SimulatedStoreTransaction.swift
|
|
// RevenueCat
|
|
//
|
|
// Created by Antonio Pallares on 30/7/25.
|
|
// Copyright © 2025 RevenueCat, Inc. All rights reserved.
|
|
//
|
|
|
|
import Foundation
|
|
|
|
struct SimulatedStoreTransaction: StoreTransactionType, Equatable {
|
|
|
|
let productIdentifier: String
|
|
let purchaseDate: Date
|
|
let transactionIdentifier: String
|
|
|
|
var hasKnownPurchaseDate: Bool { return true }
|
|
var hasKnownTransactionIdentifier: Bool { return true }
|
|
var quantity: Int { return 1 }
|
|
|
|
let storefront: Storefront?
|
|
|
|
let jwsRepresentation: String?
|
|
|
|
let environment: StoreEnvironment? = nil
|
|
|
|
func finish(_ wrapper: any PaymentQueueWrapperType, completion: @escaping @Sendable () -> Void) {
|
|
// no-op
|
|
completion()
|
|
}
|
|
|
|
}
|