Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Reformat
  • Loading branch information
Goooler committed Mar 4, 2022
commit 69f403685c3ded4a11240f8ee4e6054ca900f591
144 changes: 72 additions & 72 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ jobs:
timeout-minutes: 15
strategy:
matrix:
os: [macos-latest, ubuntu-latest]
api-level: [16, 23, 29]
target: [default, google_apis]
arch: [x86]
os: [ macos-latest, ubuntu-latest ]
api-level: [ 16, 23, 29 ]
target: [ default, google_apis ]
arch: [ x86 ]
exclude:
- os: ubuntu-latest
api-level: 23
Expand All @@ -47,77 +47,77 @@ jobs:
arch: x86_64

steps:
- name: checkout
uses: actions/checkout@v3
- name: checkout
uses: actions/checkout@v3

- name: validate gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: validate gradle wrapper
uses: gradle/wrapper-validation-action@v1

- name: build, test and lint
run: |
npm install
npm run build
npm run lint
npm test
- name: build, test and lint
run: |
npm install
npm run build
npm run lint
npm test

- name: Java 15
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 15
- name: Gradle cache
uses: gradle/gradle-build-action@v2
- name: AVD cache
uses: actions/cache@v2
id: avd-cache
with:
path: |
~/.android/avd/*
~/.android/adb*
~/.android/debug.keystore
key: avd-${{ matrix.api-level }}-${{ matrix.os }}-${{ matrix.target }}
- name: Java 15
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 15
- name: Gradle cache
uses: gradle/gradle-build-action@v2
- name: AVD cache
uses: actions/cache@v2
id: avd-cache
with:
path: |
~/.android/avd/*
~/.android/adb*
~/.android/debug.keystore
key: avd-${{ matrix.api-level }}-${{ matrix.os }}-${{ matrix.target }}

- name: assemble tests
uses: gradle/gradle-build-action@v2
with:
build-root-directory: test-fixture
arguments: assembleAndroidTest
- name: assemble tests
uses: gradle/gradle-build-action@v2
with:
build-root-directory: test-fixture
arguments: assembleAndroidTest

- name: run emulator to generate snapshot for caching
if: steps.avd-cache.outputs.cache-hit != 'true'
uses: ./
with:
api-level: ${{ matrix.api-level }}
target: ${{ matrix.target }}
arch: ${{ matrix.arch }}
profile: Galaxy Nexus
cores: 2
sdcard-path-or-size: 100M
avd-name: test
force-avd-creation: false
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: false
working-directory: ./test-fixture/
channel: canary
script: echo "Generated AVD snapshot for caching."
- name: run emulator to generate snapshot for caching
if: steps.avd-cache.outputs.cache-hit != 'true'
uses: ./
with:
api-level: ${{ matrix.api-level }}
target: ${{ matrix.target }}
arch: ${{ matrix.arch }}
profile: Galaxy Nexus
cores: 2
sdcard-path-or-size: 100M
avd-name: test
force-avd-creation: false
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: false
working-directory: ./test-fixture/
channel: canary
script: echo "Generated AVD snapshot for caching."

- name: run action
uses: ./
with:
api-level: ${{ matrix.api-level }}
target: ${{ matrix.target }}
arch: ${{ matrix.arch }}
profile: Galaxy Nexus
cores: 2
ram-size: 2048M
sdcard-path-or-size: 100M
avd-name: test
force-avd-creation: false
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: true
working-directory: ./test-fixture/
channel: canary
script: |
echo $GITHUB_REPOSITORY
adb devices
./gradlew connectedDebugAndroidTest
- name: run action
uses: ./
with:
api-level: ${{ matrix.api-level }}
target: ${{ matrix.target }}
arch: ${{ matrix.arch }}
profile: Galaxy Nexus
cores: 2
ram-size: 2048M
sdcard-path-or-size: 100M
avd-name: test
force-avd-creation: false
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: true
working-directory: ./test-fixture/
channel: canary
script: |
echo $GITHUB_REPOSITORY
adb devices
./gradlew connectedDebugAndroidTest
58 changes: 29 additions & 29 deletions .github/workflows/manually.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,36 +42,36 @@ jobs:
timeout-minutes: 15

steps:
- name: checkout
uses: actions/checkout@v3
- name: checkout
uses: actions/checkout@v3

- name: validate gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: validate gradle wrapper
uses: gradle/wrapper-validation-action@v1

- name: build, test and lint
run: |
npm install
npm run build
npm run lint
npm test
- name: build, test and lint
run: |
npm install
npm run build
npm run lint
npm test

- name: Java 15
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 15
- name: Gradle cache
uses: gradle/gradle-build-action@v2
- name: Java 15
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 15
- name: Gradle cache
uses: gradle/gradle-build-action@v2

- name: run action
uses: ./
with:
api-level: ${{ github.event.inputs.api-level }}
target: ${{ github.event.inputs.target }}
arch: ${{ github.event.inputs.arch }}
profile: Galaxy Nexus
emulator-options: ${{ github.event.inputs.emulator-options }}
emulator-build: ${{ github.event.inputs.emulator-build }}
channel: ${{ github.event.inputs.channel }}
working-directory: ./test-fixture/
script: ${{ github.event.inputs.script }}
- name: run action
uses: ./
with:
api-level: ${{ github.event.inputs.api-level }}
target: ${{ github.event.inputs.target }}
arch: ${{ github.event.inputs.arch }}
profile: Galaxy Nexus
emulator-options: ${{ github.event.inputs.emulator-options }}
emulator-build: ${{ github.event.inputs.emulator-build }}
channel: ${{ github.event.inputs.channel }}
working-directory: ./test-fixture/
script: ${{ github.event.inputs.script }}