Skip to content

Commit

Permalink
fix(test): fix the issue for android and ios test ci
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhiXin18 committed Sep 30, 2024
1 parent 05dec43 commit c3b7385
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions integration_test/e2e_successful_register_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ void main() {
await registerRobot.tapRegisterButton();
await tester.pumpAndSettle(const Duration(seconds: 2));
registerRobot.verifyPartSuccess(); // Verify its at saved place screen
await tester.pumpAndSettle(const Duration(seconds: 2));

// Define your addresses
List<Address> addresses = [
Expand Down Expand Up @@ -107,6 +108,7 @@ void main() {
await registerRobot.tapRegisterButton();
await tester.pumpAndSettle(const Duration(seconds: 2));
registerRobot.verifyPartSuccess(); // Verify its at saved place screen
await tester.pumpAndSettle(const Duration(seconds: 2));

// Define your addresses
List<Address> addresses = [
Expand Down
10 changes: 10 additions & 0 deletions integration_test/e2e_unsuccessful_register_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -261,26 +261,36 @@ void main() {
// Test 5: Only one checkbox is checked
await registerRobot.dismissKeyboard();
await tester.pumpAndSettle(const Duration(seconds: 4));
await tester.fling(scrollableFinder, Offset(0, -300), 1500); // Fling upwards
await tester.pumpAndSettle(); // Allow time for scrolling to finish
//await Future.delayed(const Duration(seconds: 4));
await registerRobot.tapTermsCheckbox();
await registerRobot.dismissKeyboard();
await tester.pumpAndSettle(const Duration(seconds: 4));
//await Future.delayed(const Duration(seconds: 4));
await tester.fling(scrollableFinder, Offset(0, -300), 1500); // Fling upwards
await tester.pumpAndSettle(); // Allow time for scrolling to finish
await registerRobot.tapGetStartedButton();
await Future.delayed(const Duration(seconds: 2));
await registerRobot.verifyErrorMessage(
'Please accept the terms and conditions and allow notifications.');

await registerRobot.dismissKeyboard();
await tester.pumpAndSettle(const Duration(seconds: 4));
await tester.fling(scrollableFinder, Offset(0, -300), 1500); // Fling upwards
await tester.pumpAndSettle(); // Allow time for scrolling to finish
//await Future.delayed(const Duration(seconds: 4));
await registerRobot.tapTermsCheckbox();
await registerRobot.dismissKeyboard();
await tester.pumpAndSettle(const Duration(seconds: 4));
await tester.fling(scrollableFinder, Offset(0, -300), 1500); // Fling upwards
await tester.pumpAndSettle(); // Allow time for scrolling to finish
//await Future.delayed(const Duration(seconds: 4));
await registerRobot.tapNotificationCheckbox();
await registerRobot.dismissKeyboard();
await tester.pumpAndSettle(const Duration(seconds: 4));
await tester.fling(scrollableFinder, Offset(0, -300), 1500); // Fling upwards
await tester.pumpAndSettle(); // Allow time for scrolling to finish
//await Future.delayed(const Duration(seconds: 4));
await registerRobot.tapGetStartedButton();
await Future.delayed(const Duration(seconds: 2));
Expand Down

0 comments on commit c3b7385

Please sign in to comment.