Skip to content

Chore: update irmago to 0.16.0 and go toolchain to 1.22.5 #854

Chore: update irmago to 0.16.0 and go toolchain to 1.22.5

Chore: update irmago to 0.16.0 and go toolchain to 1.22.5 #854

Workflow file for this run

# Workflow to check whether changes in a pull request fulfill all requirements.
# We execute build stages in separate jobs to prevent artifact duplication.
name: Status checks
on:
pull_request:
schedule:
# Run every sunday at noon. We run this on sunday such that we can utilize the free test minutes we get from Firebase.
# The weekly run ensures that cached resources don't expire.
- cron: "0 12 * * 0"
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
jobs:
# We make sure that lint succeeds before we start any other job to
# prevent that the setup-build-environment action runs in parallel.
lint:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- run: bundle exec fastlane lint
unit-test:
runs-on: ubuntu-latest
needs: lint
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- run: bundle exec fastlane unit_test
build-irmagobridge-ios:
runs-on: macos-13 # MacOS version is pinned, because it determines which XCode version is used.
needs: lint
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- run: bundle exec fastlane ios_build_irmagobridge
- uses: actions/upload-artifact@v4
with:
name: irmagobridge-ios
path: ios/Runner/Irmagobridge.xcframework/
build-irmagobridge-android:
runs-on: ubuntu-latest
needs: lint
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- run: bundle exec fastlane android_build_irmagobridge
- uses: actions/upload-artifact@v4
with:
name: irmagobridge-android
path: android/irmagobridge/irmagobridge.aar
build-prototypes-android:
runs-on: ubuntu-latest
needs: build-irmagobridge-android
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: true
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- name: Download irmagobridge artifact
uses: actions/download-artifact@v4
with:
name: irmagobridge-android
path: android/irmagobridge/
- run: flutter build apk --flavor alpha -t lib/main_prototypes.dart
- uses: actions/upload-artifact@v4
with:
name: prototypes-alpha-android
path: ./build/app/outputs/apk/alpha/release/*.apk
build-app-ios-alpha:
runs-on: macos-13 # MacOS version is pinned, because it determines which XCode version is used.
needs: build-irmagobridge-ios
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: true
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- name: Download irmagobridge artifact
uses: actions/download-artifact@v4
with:
name: irmagobridge-ios
path: ios/Runner/Irmagobridge.xcframework/
- name: Decode binary environment secrets
env:
APPLE_DEVELOPMENT_CERTIFICATE: ${{ secrets.APPLE_DEVELOPMENT_CERTIFICATE }}
APPLE_DEVELOPMENT_PROVISIONING_PROFILE: ${{ secrets.APPLE_DEVELOPMENT_PROVISIONING_PROFILE }}
run: |
mkdir -p ./fastlane/profiles
echo $APPLE_DEVELOPMENT_CERTIFICATE | base64 --decode > ./fastlane/profiles/ios_development.p12
echo $APPLE_DEVELOPMENT_PROVISIONING_PROFILE | base64 --decode > ./fastlane/profiles/development.mobileprovision
- name: Build
run: >
bundle exec fastlane ios_build_app
flavor:alpha
certificate_path:profiles/ios_development.p12
certificate_password:${{ secrets.APPLE_DEVELOPMENT_CERTIFICATE_PASSWORD }}
provisioning_profile_path:profiles/development.mobileprovision
code_signing_identity:"iPhone Developer"
- uses: actions/upload-artifact@v4
with:
name: app-alpha-ios
path: ./fastlane/build/*.ipa
build-app-android:
runs-on: ubuntu-latest
needs: build-irmagobridge-android
strategy:
matrix:
flavor: [ alpha, beta ]
type: [ apk, appbundle ]
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: true
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- name: Download irmagobridge artifact
uses: actions/download-artifact@v4
with:
name: irmagobridge-android
path: android/irmagobridge/
- name: Decode binary environment secrets
env:
ANDROID_DEVELOPMENT_SIGNING_KEYSTORE: ${{ secrets.ANDROID_DEVELOPMENT_SIGNING_KEYSTORE }}
run: |
mkdir -p ./fastlane/profiles
echo $ANDROID_DEVELOPMENT_SIGNING_KEYSTORE | base64 --decode > ./fastlane/profiles/keystore.jks
- name: Build
run: >
bundle exec fastlane android_build_${{ matrix.type }}
flavor:${{ matrix.flavor }}
keystore_path:profiles/keystore.jks
key_alias:android-signing-development
keystore_password:${{ secrets.ANDROID_DEVELOPMENT_SIGNING_KEYSTORE_PASSWORD }}
key_password:${{ secrets.ANDROID_DEVELOPMENT_SIGNING_KEYSTORE_PASSWORD }}
- uses: actions/upload-artifact@v4
with:
name: app-${{ matrix.flavor }}-android-${{ matrix.type }}
path: ./fastlane/build/*
build-integration-test-ios:
runs-on: macos-13 # MacOS version is pinned, because it determines which XCode version is used.
needs: build-irmagobridge-ios
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: true
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- name: Download irmagobridge artifact
uses: actions/download-artifact@v4
with:
name: irmagobridge-ios
path: ios/Runner/Irmagobridge.xcframework/
- name: Decode binary environment secrets
env:
APPLE_DEVELOPMENT_CERTIFICATE: ${{ secrets.APPLE_DEVELOPMENT_CERTIFICATE }}
APPLE_DEVELOPMENT_PROVISIONING_PROFILE: ${{ secrets.APPLE_DEVELOPMENT_PROVISIONING_PROFILE }}
run: |
mkdir -p ./fastlane/profiles
echo $APPLE_DEVELOPMENT_CERTIFICATE | base64 --decode > ./fastlane/profiles/ios_development.p12
echo $APPLE_DEVELOPMENT_PROVISIONING_PROFILE | base64 --decode > ./fastlane/profiles/development.mobileprovision
- name: Build
run: >
bundle exec fastlane ios_build_integration_test
certificate_path:profiles/ios_development.p12
certificate_password:${{ secrets.APPLE_DEVELOPMENT_CERTIFICATE_PASSWORD }}
provisioning_profile_path:profiles/development.mobileprovision
code_signing_identity:"iPhone Developer"
- uses: actions/upload-artifact@v4
with:
name: integration-test-ios
path: ./fastlane/build/*.zip
build-integration-test-android:
runs-on: ubuntu-latest
needs: build-irmagobridge-android
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: true
- name: Setup build environment
uses: ./.github/actions/setup-build-environment
- name: Download irmagobridge artifact
uses: actions/download-artifact@v4
with:
name: irmagobridge-android
path: android/irmagobridge/
- run: bundle exec fastlane android_build_integration_test
- uses: actions/upload-artifact@v4
with:
name: integration-test-android
path: ./fastlane/build/*.apk
integration-test-ios:
runs-on: ubuntu-latest
container: google/cloud-sdk:latest
needs:
- build-integration-test-ios
- unit-test # To prevent that test resources are used when we already know there is an issue.
concurrency: integration-test-ios # To prevent that we use too much test resources at the same time.
steps:
- name: Download test artifacts
uses: actions/download-artifact@v4
with:
name: integration-test-ios
path: .
- name: Authenticate to Firebase
env:
GCLOUD_SERVICE_KEY: ${{ secrets.GCLOUD_SERVICE_KEY }}
run: gcloud auth activate-service-account --key-file <(echo $GCLOUD_SERVICE_KEY)
shell: bash
- name: Set Firebase project
run: gcloud config set project yivimobile
- name: Run integration tests
run: gcloud firebase test ios run --test ios_tests.zip --timeout 20m --device=model=iphone8,orientation=portrait --device=model=iphone8,orientation=landscape
integration-test-android:
runs-on: ubuntu-latest
container: google/cloud-sdk:latest
needs:
- build-integration-test-android
- unit-test # To prevent that test resources are used when we already know there is an issue.
concurrency: integration-test-android # To prevent that we use too much test resources at the same time.
steps:
- name: Download test artifacts
uses: actions/download-artifact@v4
with:
name: integration-test-android
path: .
- name: Authenticate to Firebase
env:
GCLOUD_SERVICE_KEY: ${{ secrets.GCLOUD_SERVICE_KEY }}
run: gcloud auth activate-service-account --key-file <(echo $GCLOUD_SERVICE_KEY)
shell: bash
- name: Set Firebase project
run: gcloud config set project yivimobile
- name: Run integration tests
run: gcloud firebase test android run --use-orchestrator --app app-alpha-debug.apk --test app-alpha-debug-androidTest.apk --timeout 20m --device=model=Pixel2,version=28,orientation=portrait --device=model=Pixel2,version=28,orientation=landscape