Skip to content

Commit ec3fb33

Browse files
committed
Update CONTRIBUTING.md for running integration tests
1 parent e0af8b7 commit ec3fb33

File tree

1 file changed

+20
-4
lines changed

1 file changed

+20
-4
lines changed

CONTRIBUTING.md

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,21 +111,37 @@ flutter test
111111
### End-to-end (e2e) tests
112112

113113
E2e tests are those which directly communicate with Firebase, whose results cannot be mocked. These tests run directly from
114-
an example application. To run e2e tests, run the `flutter drive` command from the plugins main `example` directory, targeting the
115-
entry e2e test file.
114+
an example application. To run e2e tests, run the `flutter test` (for Android & iOS) or the `flutter drive` (for macOS & web)
115+
command from the plugins main `example` directory, targeting the entry e2e test file.
116116

117117
> Some packages use Firebase Emulator Suite to run tests. To learn more, [visit the official documentation](https://firebase.google.com/docs/emulator-suite).
118118
119+
To start the Firebase Emulator, run these commands:
120+
121+
```bash
122+
cd .github/workflows/scripts
123+
firebase emulators:start --only auth,firestore,functions,storage,database --project flutterfire-e2e-tests
124+
```
125+
126+
To run tests against Android & iOS environments, run these commands:
127+
128+
```bash
129+
cd packages/firebase_auth/firebase_auth/example
130+
flutter test integration_test/firebase_auth_e2e_test.dart
131+
```
132+
133+
To run tests against macOS environments, run these commands:
134+
119135
```bash
120136
cd packages/firebase_auth/firebase_auth/example
121-
flutter drive --target=./test_driver/firebase_auth_e2e.dart
137+
flutter drive --target=./integration_test/firebase_auth_e2e_test.dart
122138
```
123139

124140
To run tests against web environments, run the command as a release build:
125141

126142
```bash
127143
cd packages/firebase_auth/firebase_auth/example
128-
flutter drive --target=./test_driver/firebase_auth_e2e.dart --release -d chrome
144+
flutter drive --target=./integration_test/firebase_auth_e2e_test.dart --release -d chrome
129145
```
130146

131147
### Using Melos

0 commit comments

Comments
 (0)