Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 16 additions & 8 deletions .github/workflows/android_alarm_manager_plus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,16 @@ jobs:
timeout-minutes: 30
steps:
- name: "Checkout repository"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Install Flutter"
run: ./.github/workflows/scripts/install-flutter.sh stable
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh

# Required for Android builds
- uses: actions/setup-java@v1
# Required for Android builds
- uses: actions/setup-java@v2
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I experimented with removing this step as suggested in one of other PRs (because of https://github.com/actions/runner-images/blob/main/images/macos/macos-12-Readme.md#java saying that such runners already have Java 11), but couldn't build the project due to missing Java 11. Thus, returned the step again.

with:
distribution: "temurin"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

setup-java in v2 requires to specify the distribution type, thus, this addition.

java-version: "11"

- name: "Build Example"
Expand All @@ -40,26 +41,33 @@ jobs:
android_integration_test:
runs-on: macos-latest
timeout-minutes: 30
strategy:
matrix:
android-api-level: [21, 26, 32]
Comment on lines +44 to +46
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ohh that's cool, simpler than what I thought.


steps:
- name: "Checkout repository"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Install Flutter"
run: ./.github/workflows/scripts/install-flutter.sh stable
- name: "Install Tools"
run: ./.github/workflows/scripts/install-tools.sh

# Required for Android builds
- uses: actions/setup-java@v1
# Required for Android builds
- uses: actions/setup-java@v2
with:
distribution: "temurin"
java-version: "11"

- name: "Bootstrap Workspace"
run: melos bootstrap
- name: "Android Integration Test"
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 30
arch: x86_64
api-level: ${{ matrix.android-api-level }}
cores: 3
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MacOS runner has 3 cores available, while android-emulator-runner uses 2 by default. Specifying this value in effort to get higher performance.

target: google_apis
arch: x86_64
force-avd-creation: false
profile: Nexus 5X
script: ./.github/workflows/scripts/integration-test.sh android android_alarm_manager_example