mirror of
https://github.com/game-ci/unity-actions.git
synced 2026-01-29 04:39:07 +08:00
Add caching to workflow
This commit is contained in:
59
.github/workflows/main.yml
vendored
59
.github/workflows/main.yml
vendored
@@ -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
|
|
||||||
|
|||||||
Reference in New Issue
Block a user