Skip to content

Commit 8dd3032

Browse files
authored
chore: combine OSX and Windows CI (#406)
* rename file * rename the variable for OSX test projects * rename the variable for Win test projects * remove windows.yml
1 parent 1dd8be5 commit 8dd3032

File tree

2 files changed

+71
-72
lines changed

2 files changed

+71
-72
lines changed

.yamato/windows.yml renamed to .yamato/UnityToonShader-test.yml

Lines changed: 71 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,27 @@
44
#
55
#
66

7-
test_projects:
7+
osx_test_projects:
8+
- project_prefix: HdrpGraphicsTest
9+
unity_editors:
10+
- version: 2021.3
11+
- version: 2022.3
12+
- version: 6000.0
13+
- project_prefix: LegacyGraphicsTest
14+
unity_editors:
15+
- version: 2021.3
16+
- version: 2022.3
17+
- project_prefix: UniversalGraphicsTest
18+
unity_editors:
19+
- version: 2021.3
20+
- version: 6000.0
21+
- project_prefix: UniversalGraphicsTestECS
22+
unity_editors:
23+
- version: 2022.3
24+
- version: 6000.0
25+
26+
27+
win_test_projects:
828
- project_prefix: LegacyStereoGraphicsTest
929
utr_arguments: --extra-editor-arg="-force-d3d11"
1030
unity_editors:
@@ -76,9 +96,58 @@ test_projects:
7696
- version: 2021.3
7797
- version: 6000.0
7898

99+
79100
---
80101

81-
{% for test_project in test_projects %}
102+
# OSX Metal
103+
{% for test_project in osx_test_projects %}
104+
{% for unity_editor in test_project.unity_editors %}
105+
106+
{% assign project_name = test_project.project_prefix | append: '-' | concat: unity_editor.version %}
107+
108+
{{ project_name }}_OSX_Metal_playmode_mono_Linear:
109+
name: {{ project_name }} on OSX_Metal_playmode_mono_Linear
110+
agent:
111+
type: {{ metal_platform.type }}
112+
model: {{ metal_platform.model }}
113+
image: {{ metal_platform.image }}
114+
flavor: {{ metal_platform.flavor }}
115+
variables:
116+
UPM_REGISTRY: https://artifactory-slo.bf.unity3d.com/artifactory/api/npm/upm-candidates
117+
UTR_VERSION: current
118+
commands:
119+
- command: curl -s https://artifactory.prd.it.unity3d.com/artifactory/unity-tools-local/utr-standalone/utr --output TestProjects/{{ project_name }}/utr
120+
- chmod +x TestProjects/{{ project_name }}/utr
121+
- command: ssh -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" bokken@$BOKKEN_DEVICE_IP "bash -lc 'pip3 install --upgrade pip'"
122+
- command: ssh -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" bokken@$BOKKEN_DEVICE_IP "bash -lc 'pip3 install unity-downloader-cli --index-url https://artifactory.prd.it.unity3d.com/artifactory/api/pypi/pypi/simple'"
123+
- command: rsync -aq -e 'ssh -i ~/.ssh/id_rsa_macmini' --append --timeout=30 $YAMATO_SOURCE_DIR bokken@$BOKKEN_DEVICE_IP:~/
124+
retries: 2
125+
- command: scp -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" ~/.ssh/id_rsa_macmini bokken@$BOKKEN_DEVICE_IP:~/.ssh/id_rsa_macmini
126+
retries: 2
127+
- command: ssh -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" bokken@$BOKKEN_DEVICE_IP '$(python3 -m site --user-base)/bin/unity-downloader-cli -u {{ unity_editor.version }} -c editor -c il2cpp --wait --published-only'
128+
retries: 2
129+
- command: |5-
130+
131+
ssh -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" bokken@$BOKKEN_DEVICE_IP "export UPM_REGISTRY=https://artifactory-slo.bf.unity3d.com/artifactory/api/npm/upm-candidates; echo \$UPM_REGISTRY; cd ~/com.unity.toonshader/TestProjects/{{ project_name }} && ~/com.unity.toonshader/TestProjects/{{ project_name }}/utr --artifacts_path=/Users/bokken/com.unity.toonshader/TestProjects/{{ project_name }}/test-results --editor-location=/Users/bokken/.Editor --extra-editor-arg="-colorspace=Linear" --reruncount=2 --scripting-backend=Mono2x --suite=playmode --testproject=/Users/bokken/com.unity.toonshader/TestProjects/{{ project_name }}"
132+
UTR_RESULT=$?
133+
mkdir -p TestProjects/{{ project_name }}/test-results/
134+
scp -i ~/.ssh/id_rsa_macmini -o "StrictHostKeyChecking=no" -r bokken@$BOKKEN_DEVICE_IP:/Users/bokken/com.unity.toonshader/TestProjects/{{ project_name }}/test-results/ TestProjects/{{ project_name }}/test-results/
135+
exit $UTR_RESULT
136+
triggers:
137+
branches:
138+
only:
139+
- "/.*/"
140+
artifacts:
141+
logs:
142+
paths:
143+
- "**/test-results/**"
144+
- "TestProjects/{{ project_name }}/Logs/*.log"
145+
{% endfor %}
146+
{% endfor %}
147+
148+
149+
# Windows
150+
{% for test_project in win_test_projects %}
82151
{% for unity_editor in test_project.unity_editors %}
83152

84153
{% assign project_name = test_project.project_prefix | append: '-' | concat: unity_editor.version %}

.yamato/osx_metal.yml

Lines changed: 0 additions & 70 deletions
This file was deleted.

0 commit comments

Comments
 (0)