mirror of
https://github.com/inaturalist/iNaturalistReactNative.git
synced 2026-06-19 13:11:23 -04:00
Trying to cache build folder on GitHub
This commit is contained in:
20
.github/workflows/android.yml
vendored
20
.github/workflows/android.yml
vendored
@@ -55,6 +55,13 @@ jobs:
|
||||
with:
|
||||
path: node_modules
|
||||
key: node-modules-${{ hashFiles('**/package-lock.json') }}
|
||||
|
||||
- name: Cache android build folder
|
||||
uses: actions/cache@v3
|
||||
id: androidcache
|
||||
with:
|
||||
path: android/app/build
|
||||
key: android-app-build-${{ hashFiles('**/ci-build-cache-timestamp.txt') }}
|
||||
|
||||
- name: Rebuild detox from cache
|
||||
if: steps.cache.outputs.cache-hit == 'true'
|
||||
@@ -90,6 +97,7 @@ jobs:
|
||||
distribution: 'zulu'
|
||||
|
||||
- name: Build for detox
|
||||
if: steps.androidcache.outputs.cache-hit != 'true'
|
||||
run: npm run e2e:build:android
|
||||
|
||||
- name: Android Emulator
|
||||
@@ -102,11 +110,15 @@ jobs:
|
||||
$ANDROID_HOME/platform-tools/adb devices
|
||||
echo "Emulator started"
|
||||
|
||||
- name: Reverse ADB
|
||||
run: adb reverse tcp:8081 tcp:8081
|
||||
|
||||
- name: Android Detox
|
||||
run: npm start & npm run e2e:test:android -- --cleanup --debug-synchronization 200
|
||||
run: npm run e2e:test:android -- --cleanup --debug-synchronization 500 --take-screenshots failing --record-videos failing -l trace
|
||||
|
||||
- name: Store Detox artifacts on test failure
|
||||
uses: actions/upload-artifact@v3
|
||||
if: failure()
|
||||
with:
|
||||
name: detox-artifacts
|
||||
path: artifacts # Default path for Detox artifacts
|
||||
|
||||
notify:
|
||||
name: Notify Slack
|
||||
|
||||
1
ci-build-cache-timestamp.txt
Normal file
1
ci-build-cache-timestamp.txt
Normal file
@@ -0,0 +1 @@
|
||||
22-12-16 12:43
|
||||
Reference in New Issue
Block a user