-
-
Notifications
You must be signed in to change notification settings - Fork 178
84 lines (77 loc) · 2.48 KB
/
test.yaml
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
81
82
83
84
name: Test
on: push
jobs:
test-dotnet:
runs-on: ubuntu-latest
env:
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
NUGET_XMLDOC_MODE: skip
steps:
- uses: actions/checkout@v2
- uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- run: dotnet test -c Debug ./VContainer.StandaloneTests
test-unity:
runs-on: ubuntu-latest
strategy:
matrix:
unityVersion:
- 2021.1.4f1
- 2020.3.5f1
- 2019.4.25f1
- 2019.3.15f1
# feature: ['None', 'UniTask', 'ECS']
# feature: ['Default', 'UniTask', 'CodeGen']
feature: ['Default', 'UniTask']
include:
- unityVersion: 2021.1.4f1
license: UNITY_LICENSE_2021_1
- unityVersion: 2020.3.5f1
license: UNITY_LICENSE_2020_3
- unityVersion: 2019.4.25f1
license: UNITY_LICENSE_2019_4
- unityVersion: 2019.3.15f1
license: UNITY_LICENSE_2019_3
- unityVersion: 2021.1.4f1
feature: 'ECS'
license: UNITY_LICENSE_2021_1
# - unityVersion: 2018.4.31f1
# license: UNITY_LICENSE_2018_4
# externalPackage: 'None'
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: VContainer/Library
key: Library-VContainer-${{ matrix.unityVersion }}-${{ matrix.feature }}
restore-keys: |
Library-VContainer-
Library-
- name: Add UniTask
if: matrix.feature == 'UniTask'
shell: bash
run: |
sed -i '2a "com.cysharp.unitask": "https://github.com/Cysharp/UniTask.git?path=src/UniTask/Assets/Plugins/UniTask",' ./VContainer/Packages/manifest.json
- name: Add Unity.Entities
if: matrix.feature == 'ECS'
shell: bash
run: |
sed -i '2a "com.unity.entities": "0.17.0-preview.41",' ./VContainer/Packages/manifest.json
- name: Enable CodeGen
if: matrix.feature == 'CodeGen'
shell: bash
run: |
sed -i '4a "VContainer.EnableCodeGen",' ./VContainer/Assets/VContainer/Tests/VContainer.Tests.asmdef
- uses: game-ci/[email protected]
env:
UNITY_LICENSE: ${{ secrets[matrix.license] }}
with:
projectPath: ./VContainer
unityVersion: ${{ matrix.unityVersion }}
# customParameters: -testSettingsFile ./testSettings.json
- uses: actions/upload-artifact@v2
with:
name: Test results
path: artifacts