Sample conference app used for Patrol webinars and live streams. The project shows how to write E2E tests for realistic Flutter user flows: onboarding, login, agenda browsing, speakers, session details, and native interactions such as permissions or maps.
Requirements:
- Flutter matching the version range from
pubspec.yaml(>=3.41.0 <4.0.0) - Android Studio or Xcode with a running emulator/simulator
Install dependencies:
flutter pub getRun the development flavor:
flutter run --flavor dev -t lib/main_dev.dartRun the test flavor, which is also used by Patrol:
flutter run --flavor tst -t lib/main_tst.dartThe app uses Google Maps, so before opening map screens you need to provide an API key with the Google Maps SDK enabled for Android and/or iOS.
Android: replace <YOUR_API_KEY> in android/app/build.gradle for the dev and tst flavors:
manifestPlaceholders = [
appLabel: "FTS DEV",
authHostName: "auth.patrol-webinar.test.lncd.pl",
googleMapsApiKey: "<YOUR_API_KEY>"
]iOS: replace <YOUR_API_KEY> in ios/Runner/AppDelegate.swift:
GMSServices.provideAPIKey("<YOUR_API_KEY>")Do not commit a real key if the repository is public or shared outside a trusted team.
First, install the Patrol CLI:
dart pub global activate patrol_cliRun all tests:
patrol testRun a single scenario:
patrol test -t patrol_test/scenarios/login_logout_test.dartSome scenarios require data passed through --dart-define, for example a test account or Mailpit access:
patrol test -t patrol_test/scenarios/login_logout_test.dart \
--dart-define=EMAIL="user@example.com" \
--dart-define=PASSWORD="password"Variables used by the tests include EMAIL, PASSWORD, FIRSTNAME, LASTNAME, DOMAIN_NAME, MAILPIT_LOGIN, MAILPIT_PASSWORD, and MAILBOX_API_KEY.