File tree Expand file tree Collapse file tree 1 file changed +23
-5
lines changed Expand file tree Collapse file tree 1 file changed +23
-5
lines changed Original file line number Diff line number Diff line change 23
23
uses : android-actions/setup-android@v3
24
24
25
25
- name : Grant Gradlew Permissions
26
- working-directory : Cod
26
+ working-directory : Cod
27
27
run : chmod +x ./gradlew
28
+
28
29
29
30
- name : Set up Node.js
30
31
uses : actions/setup-node@v3
34
35
- name : Install Firebase Tools
35
36
run : npm install -g firebase-tools
36
37
37
- - name : Run Tests with Firebase Emulators
38
- working-directory : Cod
38
+ - name : Start Firebase Emulator (Background)
39
39
run : |
40
- firebase emulators:exec --only auth,database --project demo-project --host 0.0.0.0 \
41
- "./gradlew testDebugUnitTest connectedDebugAndroidTest"
40
+ firebase emulators:start --only auth,database --project demo-project &
41
+ sleep 20 # Ensure emulators are fully started
42
42
43
+ - name : Run Unit Tests (Located in `test/`)
44
+ working-directory : Cod
45
+ run : ./gradlew testDebugUnitTest
46
+
47
+ - name : Start Android Emulator for UI & Integration Tests
48
+ uses : reactivecircus/android-emulator-runner@v2
49
+ with :
50
+ api-level : 33
51
+ arch : x86_64
52
+ profile : Nexus 6
53
+ working-directory : Cod
54
+ script : |
55
+ # Ensure Emulator is Ready
56
+ adb wait-for-device
57
+ sleep 10
58
+
59
+ # Run UI & Integration Tests (Located in `androidTest/`)
60
+ ./gradlew connectedDebugAndroidTest
You can’t perform that action at this time.
0 commit comments