Skip to content

Commit 26d775f

Browse files
committed
test: add test for logInAppPurchase
1 parent 2a8d6c8 commit 26d775f

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

tests/integration_test/firebase_analytics/firebase_analytics_e2e_test.dart

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,27 @@ void main() {
170170
);
171171
});
172172

173+
test(
174+
'logInAppPurchase',
175+
() async {
176+
await expectLater(
177+
FirebaseAnalytics.instance.logInAppPurchase(
178+
currency: 'USD',
179+
freeTrial: false,
180+
price: 4.99,
181+
priceIsDiscounted: false,
182+
productID: 'com.example.product',
183+
productName: 'Example Product',
184+
quantity: 1,
185+
subscription: true,
186+
value: 4.99,
187+
),
188+
completes,
189+
);
190+
},
191+
skip: defaultTargetPlatform != TargetPlatform.iOS,
192+
);
193+
173194
test('setUserId', () async {
174195
await expectLater(
175196
FirebaseAnalytics.instance.setUserId(id: 'foo'),

0 commit comments

Comments
 (0)