Skip to content

Commit

Permalink
[ci] Run android integration test and rendering test on ubuntu (#1689)
Browse files Browse the repository at this point in the history
After hardware accelerated support on Ubuntu, we can move the
integration test and rendering test to Ubuntu to save the test times.

https://github.blog/changelog/2024-04-02-github-actions-hardware-accelerated-android-virtualization-now-available/
  • Loading branch information
littleGnAl authored Apr 9, 2024
1 parent 7f10322 commit fd15755
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ jobs:
strategy:
matrix:
version: ["2.10.5", "3.x"]
runs-on: macos-12
runs-on: ubuntu-latest
timeout-minutes: 120
env:
TEST_APP_ID: ${{ secrets.MY_APP_ID }}
Expand All @@ -98,7 +98,11 @@ jobs:
- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ matrix.version }}
- run: flutter config --enable-macos-desktop
- name: Enable KVM
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: run flutter android integration tests
uses: reactivecircus/android-emulator-runner@v2
with:
Expand Down Expand Up @@ -233,7 +237,6 @@ jobs:
build_android_ubuntu:
name: Build Android on Ubuntu
if: ${{ !contains(github.event.pull_request.labels.*.name, 'ci:skip') }}
needs: flutter_codestyle_check
strategy:
matrix:
version: ["2.10.5", "3.x"]
Expand Down Expand Up @@ -336,11 +339,10 @@ jobs:
run: flutter build web
working-directory: example

# Run android rendering test in macos is more stable
rendering_test_android:
name: Run Flutter Android Rendering Tests
if: ${{ !contains(github.event.pull_request.labels.*.name, 'ci:skip') }}
runs-on: macos-12
runs-on: ubuntu-latest
timeout-minutes: 120
env:
TEST_APP_ID: ${{ secrets.MY_APP_ID }}
Expand Down Expand Up @@ -378,7 +380,11 @@ jobs:
--flutter-package-name=agora_rtc_engine \
--iris-android-cdn-url=${IRIS_CDN_URL_ANDROID} \
--iris-macos-cdn-url=${IRIS_CDN_URL_MACOS}
- run: flutter config --enable-macos-desktop
- name: Enable KVM
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: run flutter android integration tests
uses: reactivecircus/android-emulator-runner@v2
with:
Expand Down

0 comments on commit fd15755

Please sign in to comment.