-
-
Notifications
You must be signed in to change notification settings - Fork 0
80 lines (68 loc) · 2.5 KB
/
Copy pathmain.yml
File metadata and controls
80 lines (68 loc) · 2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
name: CI
#on:
# pull_request: {}
# push: { branches: [main] }
on:
push:
paths-ignore:
- 'doc/**'
- '*.md'
jobs:
CI:
name: Test
runs-on: ubuntu-latest
# available list of containers here:
# https://hub.docker.com/r/unityci/editor/tags?page=1&ordering=last_updated&name=ubuntu-2020.1.17f1-base
container: unityci/editor:ubuntu-2021.1.12f1-base-0.15.0
env:
DOTNET_ROOT: '/opt/unity/Editor/Data/NetCore/Sdk-2.2.107'
steps:
- name: Activate unity
# exit code is 1 for manual activation
continue-on-error: true
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
run: |
echo "$UNITY_LICENSE" | tr -d '\r' > UnityLicenseFile.ulf
unity-editor -nographics -logFile /dev/stdout -manualLicenseFile UnityLicenseFile.ulf -quit
- name: Checkout repository
uses: actions/checkout@v1
- name: Cache Library
id: cache-library
uses: actions/cache@v2
with:
path: Library
key: Library-2020.1.17
- name: Run editor Tests
run: unity-editor -nographics -logFile /dev/stdout -runTests -testPlatform editmode -testResults Tests/editmode-results.xml -enableCodeCoverage -coverageResultsPath Tests -debugCodeOptimization
timeout-minutes: 20
- name: Run play Tests
run: unity-editor -nographics -logFile /dev/stdout -runTests -testPlatform playmode -testResults Tests/playmode-results.xml -enableCodeCoverage -coverageResultsPath Tests -debugCodeOptimization
timeout-minutes: 20
- name: Archive test results
uses: actions/upload-artifact@v2.2.4
if: always()
with:
name: Test results
path: Tests
- name: Publish test results
uses: MirageNet/nunit-reporter@v1.0.11
if: always()
with:
path: "Tests/*.xml"
access-token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/setup-node@v2
with:
node-version: '14'
- name: Release
uses: cycjimmy/semantic-release-action@v2
id: semantic
with:
extra_plugins: |
@semantic-release/changelog
@semantic-release/git
branch: master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Generate Solution
run: unity-editor -nographics -logFile /dev/stdout -customBuildName ObjectPooler -projectPath . -executeMethod UnityEditor.SyncVS.SyncSolution -quit