mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-11-17 17:57:40 +00:00
35 lines
1,019 B
Dart
35 lines
1,019 B
Dart
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:stackwallet/widgets/address_book_card.dart';
|
|
|
|
class AddressBookCardBot {
|
|
final WidgetTester tester;
|
|
|
|
const AddressBookCardBot(this.tester);
|
|
|
|
Future<void> ensureVisible() async {
|
|
await tester.ensureVisible(find.byType(AddressBookCard));
|
|
}
|
|
|
|
Future<void> toggleExpandCard() async {
|
|
await tester.tap(find.byType(AddressBookCard));
|
|
await tester.pumpAndSettle();
|
|
}
|
|
|
|
Future<void> tapDetails() async {
|
|
await tester.tap(find.byWidgetPredicate(
|
|
(widget) => widget is SubButton && widget.label == "DETAILS"));
|
|
await tester.pumpAndSettle();
|
|
}
|
|
|
|
Future<void> tapCopy() async {
|
|
await tester.tap(find.byWidgetPredicate(
|
|
(widget) => widget is SubButton && widget.label == "COPY"));
|
|
await tester.pumpAndSettle();
|
|
}
|
|
|
|
Future<void> tapSend() async {
|
|
await tester.tap(find.byWidgetPredicate(
|
|
(widget) => widget is SubButton && widget.label == "SEND FIRO"));
|
|
await tester.pumpAndSettle();
|
|
}
|
|
}
|