Skip to content

Commit cf7f737

Browse files
authored
chore: Run validation tests on all supported editors and desktop platforms (#2013)
1 parent f9228d2 commit cf7f737

File tree

6 files changed

+36
-37
lines changed

6 files changed

+36
-37
lines changed

.yamato/_triggers.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ develop_nightly:
1010
dependencies:
1111
- .yamato/_run-all.yml#run_all_tests
1212
{% for project in projects -%}
13+
{% if project.has_tests == "true" -%}
1314
- .yamato/code-coverage.yml#code_coverage_win_{{ project.name }}_{{ validation_editor }}
15+
{% endif -%}
1416
{% endfor -%}
1517

1618
develop_weekly_trunk:
@@ -43,7 +45,7 @@ pull_request_trigger:
4345
{% for project in projects -%}
4446
{% for package in project.packages -%}
4547
{% if project.validate == "true" -%}
46-
- .yamato/project-tests.yml#validate_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}
48+
- .yamato/project-publish.yml#validate_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}
4749
{% endif -%}
4850
{% endfor -%}
4951
{% for platform in test_platforms -%}
@@ -84,7 +86,7 @@ badges_test_trigger:
8486
{% for project in projects -%}
8587
{% for package in project.packages -%}
8688
{% if project.validate == "true" -%}
87-
- .yamato/project-tests.yml#validate_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}
89+
- .yamato/project-publish.yml#validate_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}
8890
{% endif -%}
8991
{% for editor in project.test_editors -%}
9092
{% if editor != "trunk" -%}

.yamato/package-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ test_{{project.name}}_{{ package.name }}_{{ editor }}_{{ platform.name }}:
1717
flavor: {{ platform.flavor}}
1818
commands:
1919
- npm install upm-ci-utils@stable -g --registry https://artifactory.prd.cds.internal.unity3d.com/artifactory/api/npm/upm-npm
20-
- {% if platform.name == "centos" %}DISPLAY=:0 {% endif %}upm-ci project test -u {{ editor }} --type package-tests --project-path {{ project.name }} --package-filter {{ package.name }}
20+
- {% if platform.name == "ubuntu" %}DISPLAY=:0 {% endif %}upm-ci project test -u {{ editor }} --type package-tests --project-path {{ project.name }} --package-filter {{ package.name }}
2121
artifacts:
2222
logs:
2323
paths:

.yamato/project-promotion.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,27 @@
33
{% for project in projects -%}
44
{% if project.publish == "true" -%}
55
{% for package in project.packages -%}
6-
# Validation job for package {{ package.name }}, only using the first entry in the
7-
# platform and editor meta data
8-
promotion_validate_{{ project.name }}_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}:
9-
name : Validate Project {{ project.name }} - Package {{ package.name }} - {{ validation_editor }} on {{ test_platforms.first.name }}
6+
{% for editor in project.test_editors -%}
7+
{% for platform in test_platforms -%}
8+
promotion_validate_{{ project.name }}_{{ package.name }}_{{ platform.name }}_{{ editor }}:
9+
name : Validate (Vetting Tests) Project {{ project.name }} - Package {{ package.name }} - {{ editor }} on {{ platform.name }}
1010
agent:
11-
type: {{ test_platforms.first.type }}
12-
image: {{ test_platforms.first.image }}
13-
flavor: {{ test_platforms.first.flavor}}
11+
type: {{ platform.type }}
12+
image: {{ platform.image }}
13+
flavor: {{ platform.flavor}}
1414
variables:
1515
UPMCI_PROMOTION: 1
1616
commands:
1717
- npm install upm-ci-utils@stable -g --registry https://artifactory.prd.cds.internal.unity3d.com/artifactory/api/npm/upm-npm
18-
- upm-ci project test -u {{ validation_editor }} --project-path {{ project.path }} --type vetting-tests --project-path {{ project.path }} --package-filter {{ package.name }}
18+
- {% if platform.name == "ubuntu" %}DISPLAY=:0 {% endif %}upm-ci project test -u {{ editor }} --project-path {{ project.path }} --type vetting-tests --project-path {{ project.path }} --package-filter {{ package.name }}
1919
artifacts:
2020
logs:
2121
paths:
2222
- "upm-ci~/test-results/**/*"
2323
dependencies:
2424
- .yamato/project-pack.yml#pack_{{ project.name }}
25+
{% endfor -%}
26+
{% endfor -%}
2527

2628
promote_{{ project.name }}_{{ package.name }}:
2729
name: Promote Project {{ project.name }} - Package {{ package.name }} to Production

.yamato/project-publish.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,26 @@
33
{% for project in projects -%}
44
{% if project.publish == "true" -%}
55
{% for package in project.packages -%}
6+
{% for editor in project.test_editors -%}
7+
{% for platform in test_platforms -%}
8+
validate_{{ package.name }}_{{ platform.name }}_{{ editor }}:
9+
name : Validate (Isolation Tests) Package {{ package.name }} - {{ editor }} on {{ platform.name }}
10+
agent:
11+
type: {{ platform.type }}
12+
image: {{ platform.image }}
13+
flavor: {{ platform.flavor}}
14+
commands:
15+
- npm install upm-ci-utils@stable -g --registry https://artifactory.prd.cds.internal.unity3d.com/artifactory/api/npm/upm-npm
16+
- {% if platform.name == "ubuntu" %}DISPLAY=:0 {% endif %}upm-ci project test -u {{ editor }} --type isolation-tests --project-path {{ project.path }} --package-filter {{ package.name }} --platform editmode
17+
artifacts:
18+
logs:
19+
paths:
20+
- "upm-ci~/test-results/**/*"
21+
dependencies:
22+
- .yamato/project-pack.yml#pack_{{ project.name }}
23+
{% endfor -%}
24+
{% endfor -%}
25+
626
publish_{{ project.name }}_{{ package.name }}:
727
name: Publish Project {{project.name }} - Package {{ package.name }} to Internal Registry
828
agent:

.yamato/project-tests.yml

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,6 @@
11
{% metadata_file .yamato/project.metafile %}
22
---
33

4-
# Validation job for package {{ package.name }}, only using the first entry in the
5-
# platform and editor meta data
6-
# Validation only occurs in editmode.
7-
8-
{% for project in projects -%}
9-
{% if project.validate == "true" %}
10-
{% for package in project.packages -%}
11-
validate_{{ package.name }}_{{ test_platforms.first.name }}_{{ validation_editor }}:
12-
name : Validate Package {{ package.name }} - {{ validation_editor }} on {{ test_platforms.first.name }}
13-
agent:
14-
type: {{ test_platforms.first.type }}
15-
image: {{ test_platforms.first.image }}
16-
flavor: {{ test_platforms.first.flavor}}
17-
commands:
18-
- npm install upm-ci-utils@stable -g --registry https://artifactory.prd.cds.internal.unity3d.com/artifactory/api/npm/upm-npm
19-
- {% if platform.name == "centos" %}DISPLAY=:0 {% endif %}upm-ci project test -u {{ validation_editor }} --type vetting-tests --project-path {{ project.path }} --package-filter {{ package.name }} --platform editmode
20-
artifacts:
21-
logs:
22-
paths:
23-
- "upm-ci~/test-results/**/*"
24-
dependencies:
25-
- .yamato/project-pack.yml#pack_{{ project.name }}
26-
{% endfor -%}
27-
{% endif -%}
28-
{% endfor -%}
29-
304
# For every platform and editor version, run its project tests without
315
# running package tests too since they are handled on their respective
326
# jobs

.yamato/project.metafile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ projects:
6262
has_tests: true
6363
test_editors:
6464
- 2021.3
65+
- 2022.2
6566
- trunk
6667

6768
# Scripting backends used by Standalone Playmode Tests

0 commit comments

Comments
 (0)