Skip to content

Commit

Permalink
chore: updated ci flow to include news media scan
Browse files Browse the repository at this point in the history
  • Loading branch information
aanorbel committed Apr 30, 2024
1 parent 6906084 commit 2a30bc4
Showing 1 changed file with 24 additions and 16 deletions.
40 changes: 24 additions & 16 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ jobs:
strategy:
matrix:
version:
- "StableFullRelease"
- "StableFdroidRelease"
- "OoniStableFullRelease"
- "OoniStableFdroidRelease"
- "DwStableFullRelease"
- "DwStableFdroidRelease"

steps:
- name: Set up JDK 17
Expand Down Expand Up @@ -47,14 +49,14 @@ jobs:
uses: actions/checkout@v4

- name: Run unit tests
run: ./gradlew testStableFullRelease
run: ./gradlew testOoniStableFullRelease

- name: Uploads test reports
uses: actions/upload-artifact@v4
if: failure()
with:
name: test-report
path: app/build/test-results/testStableFullDebugUnitTest
path: app/build/test-results/testOoniStableFullReleaseUnitTest

instrumented-test:
name: Run instrumented tests
Expand Down Expand Up @@ -85,14 +87,14 @@ jobs:
profile: pixel_3_xl
ram-size: 4096M
disable-animations: true
script: ./gradlew connectedStableFullDebugAndroidTest
script: ./gradlew connectedOoniStableFullDebugAndroidTest

- name: uploads test reports
uses: actions/upload-artifact@v4
if: failure()
with:
name: emulator-test-reports
path: app/build/reports/androidTests/connected/debug/flavors/stableFull/
path: app/build/reports/androidTests/connected/debug/flavors/ooniStableFull/

assemble-archive:
name: Archive APKs
Expand All @@ -101,10 +103,13 @@ jobs:
strategy:
matrix:
version:
- "StableFullDebug"
- "StableFdroidDebug"
- "DevFullDebug"
- "DevFullDebugAndroidTest"
- "OoniStableFullDebug"
- "OoniStableFdroidDebug"
- "OoniDevFullDebug"
- "OoniDevFullDebugAndroidTest"
- "DwStableFullDebug"
- "DwStableFdroidDebug"
- "DwDevFullDebug"
needs: [ build ]

steps:
Expand Down Expand Up @@ -148,10 +153,13 @@ jobs:
with:
name: ${{ matrix.version }}Apk
path: |
app/build/outputs/apk/devFull/debug/app-dev-full-debug.apk
app/build/outputs/apk/androidTest/devFull/debug/app-dev-full-debug-androidTest.apk
app/build/outputs/apk/stableFull/debug/app-stable-full-debug.apk
app/build/outputs/apk/stableFdroid/debug/app-stable-fdroid-debug.apk
app/build/outputs/apk/ooniStableFull/debug/app-ooni-stable-full-debug.apk
app/build/outputs/apk/ooniStableFdroid/debug/app-ooni-stable-fdroid-debug.apk
app/build/outputs/apk/ooniDevFull/debug/app-ooni-dev-full-debug.apk
app/build/outputs/apk/androidTest/ooniDevFull/debug/app-ooni-dev-full-debug-androidTest.apk
app/build/outputs/apk/dwStableFull/debug/app-dw-stable-full-debug.apk
app/build/outputs/apk/dwStableFdroid/debug/app-dw-stable-fdroid-debug.apk
app/build/outputs/apk/dwDevFull/debug/app-dw-dev-full-debug.apk
distribute:
name: Upload artifact to Firebase App Distribution
Expand All @@ -165,7 +173,7 @@ jobs:
- name: Download app APK
uses: actions/download-artifact@v4
with:
name: DevFullDebugApk
name: OoniDevFullDebugApk

- name: Upload artifact to Firebase App Distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1.7.0
Expand All @@ -174,7 +182,7 @@ jobs:
appId: ${{secrets.FIREBASE_APP_ID}}
serviceCredentialsFileContent: ${{ secrets.CREDENTIAL_FILE_CONTENT }}
groups: testers
file: devFull/debug/app-dev-full-debug.apk
file: ooniDevFull/debug/app-ooni-dev-full-debug.apk
- name: Write Summary
run: |
echo "View this release in the Firebase console: ${{ steps.uploadArtifact.outputs.FIREBASE_CONSOLE_URI }}" >> $GITHUB_STEP_SUMMARY

0 comments on commit 2a30bc4

Please sign in to comment.