You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
646 B
21 lines
646 B
import 'package:flutter/material.dart';
|
|
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:thesis_shop/screens/cart/total_price_text.dart';
|
|
import 'package:thesis_shop/stores/cart_store.dart';
|
|
|
|
void main() {
|
|
testWidgets('test total price widget', (tester) async {
|
|
await tester.pumpWidget(
|
|
MaterialApp(
|
|
home: ProviderScope(
|
|
overrides: [
|
|
totalPriceProvider.overrideWithValue(10.0),
|
|
],
|
|
child: const TotalPriceText(),
|
|
),
|
|
),
|
|
);
|
|
expect(find.text('Gesamtpreis: 10.00€'), findsOneWidget);
|
|
});
|
|
}
|
|
|