Add caching to workflow

This commit is contained in:
Webber
2020-02-01 19:26:13 +01:00
committed by Webber Takken
parent 8b5ed0628b
commit de97369cca

View File

@@ -52,6 +52,22 @@ jobs:
env: env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
activateAndThenReturnLicense:
name: returnLicense 🎈
runs-on: ubuntu-latest
steps:
# Checkout repository (required to test local actions)
- name: Checkout repository
uses: actions/checkout@v2
# Activate Unity
- name: Activate Unity
uses: webbertakken/unity-activate@v1.2
# Return License
- name: Return license
uses: webbertakken/unity-return-license@v0.1
testRunnerInEditMode: testRunnerInEditMode:
name: Test in editmode 📝 name: Test in editmode 📝
runs-on: ubuntu-latest runs-on: ubuntu-latest
@@ -62,6 +78,15 @@ jobs:
with: with:
lfs: true lfs: true
# Cache
- uses: actions/cache@v1.1.0
with:
path: test-project/Library
key: Library-test-project-${{ matrix.targetPlatform }}
restore-keys: |
Library-test-project-
Library-
# Configure test runner # Configure test runner
- name: Run tests - name: Run tests
id: testRunner id: testRunner
@@ -88,6 +113,15 @@ jobs:
with: with:
lfs: true lfs: true
# Cache
- uses: actions/cache@v1.1.0
with:
path: test-project/Library
key: Library-test-project-${{ matrix.targetPlatform }}
restore-keys: |
Library-test-project-
Library-
# Configure test runner # Configure test runner
- name: Run tests - name: Run tests
id: testRunner id: testRunner
@@ -114,6 +148,15 @@ jobs:
with: with:
lfs: true lfs: true
# Cache
- uses: actions/cache@v1.1.0
with:
path: test-project/Library
key: Library-test-project-${{ matrix.targetPlatform }}
restore-keys: |
Library-test-project-
Library-
# Configure test runner # Configure test runner
- name: Run tests - name: Run tests
id: testRunner id: testRunner
@@ -166,19 +209,3 @@ jobs:
with: with:
name: Build name: Build
path: build path: build
activateAndThenReturnLicense:
name: returnLicense 🎈
runs-on: ubuntu-latest
steps:
# Checkout repository (required to test local actions)
- name: Checkout repository
uses: actions/checkout@v2
# Activate Unity
- name: Activate Unity
uses: webbertakken/unity-activate@v1.2
# Return License
- name: Return license
uses: webbertakken/unity-return-license@v0.1