Repository navigation
187 lines (184 loc) · 7.78 KB
/
Copy pathlinux-wpt.yml
File metadata and controls
187 lines (184 loc) · 7.78 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
name: Linux WPT Tests
on:
workflow_call:
inputs:
profile:
required: true
type: string
wpt-args:
default: ""
required: false
type: string
wpt-sync-from-upstream:
default: false
required: false
type: boolean
number-of-wpt-chunks:
default: 20
required: false
type: number
binary-path:
required: true
default: ""
type: string
env:
RUST_BACKTRACE: 1
SHELL: /bin/bash
GST_PLUGIN_FEATURE_RANK: pulsesink:NONE,alsasink:NONE,jacksink:NONE,fakesink:MAX
INTERMITTENT_TRACKER_DASHBOARD_SECRET: ${{ !inputs.wpt-sync-from-upstream && secrets.INTERMITTENT_TRACKER_DASHBOARD_SECRET || '' }}
INTERMITTENT_TRACKER_DASHBOARD_SECRET_PROD: ${{ !inputs.wpt-sync-from-upstream && secrets.INTERMITTENT_TRACKER_DASHBOARD_SECRET_PROD || '' }}
INTERMITTENT_TRACKER_DASHBOARD_SECRET_STAGING: ${{ !inputs.wpt-sync-from-upstream && secrets.INTERMITTENT_TRACKER_DASHBOARD_SECRET_STAGING || '' }}
WPT_ALWAYS_SUCCEED_ARG: "${{ inputs.wpt-sync-from-upstream && '--always-succeed' || '' }}"
jobs:
# Runs the underlying job (“workload”) on a self-hosted runner if available,
# with the help of a `runner-select` job and a `runner-timeout` job.
runner-select:
runs-on: ubuntu-24.04
outputs:
unique-id: ${{ steps.select.outputs.unique-id }}
selected-runner-label: ${{ steps.select.outputs.selected-runner-label }}
selected-runner-count: ${{ steps.select.outputs.selected-runner-count }}
selected-runner-indices: ${{ steps.select.outputs.selected-runner-indices }}
runner-type-label: ${{ steps.select.outputs.runner-type-label }}
is-self-hosted: ${{ steps.select.outputs.is-self-hosted }}
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@a05e7e830e3f4d4c71bdc5a38f003f052b72668c
with:
GITHUB_TOKEN: ${{ github.token }}
# Before updating the GH action runner image for the nightly job, ensure
# that the system has a glibc version that is compatible with the one
# used by the wpt.fyi runners.
github-hosted-runner-label: ubuntu-22.04
github-hosted-runner-count: ${{ inputs.number-of-wpt-chunks }}
self-hosted-image-name: servo-ubuntu2204-wpt
self-hosted-runner-count: 3
# You can disable self-hosted runners globally by creating a repository variable named
# NO_SELF_HOSTED_RUNNERS with any non-empty value.
# <https://github.com/servo/servo/settings/variables/actions>
NO_SELF_HOSTED_RUNNERS: ${{ vars.NO_SELF_HOSTED_RUNNERS }}
# Any other boolean conditions that disable self-hosted runners go here.
force-github-hosted-runner: true
linux-wpt:
needs:
- runner-select
name: WPT [${{ needs.runner-select.outputs.unique-id }}]
runs-on: ${{ needs.runner-select.outputs.selected-runner-label }}
strategy:
fail-fast: false
matrix:
chunk_id: ${{ fromJSON(needs.runner-select.outputs.selected-runner-indices) }}
steps:
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
if: ${{ runner.environment != 'self-hosted' }}
with:
tool-cache: false
large-packages: false
swap-storage: false
- uses: servo/ci-runners/actions/checkout@a05e7e830e3f4d4c71bdc5a38f003f052b72668c
- uses: actions/download-artifact@v8
with:
name: ${{ inputs.profile }}-binary-linux
path: ${{ inputs.profile }}-binary-linux
- name: unPackage binary
run: tar -xzf ${{ inputs.profile }}-binary-linux/servo-tech-demo.tar.gz
- name: Setup Python
if: ${{ runner.environment != 'self-hosted' }}
uses: ./.github/actions/setup-python
- name: Change Mirror Priorities
if: ${{ runner.environment != 'self-hosted' }}
uses: ./.github/actions/apt-mirrors
- name: Bootstrap dependencies
timeout-minutes: 30
run: |
sudo apt update
./mach bootstrap --yes --skip-lints --skip-nextest
# FIXME #41043, #41044
sudo apt install -qy --no-install-recommends mesa-vulkan-drivers fonts-noto-cjk fonts-dejavu-extra
# FIXME #35029
sudo apt purge -y fonts-droid-fallback
- name: Sync from upstream WPT
if: ${{ inputs.wpt-sync-from-upstream }}
run: |
./mach update-wpt --sync --patch
- name: Run tests
run: |
mkdir -p wpt-filtered-logs/linux
mkdir -p wpt-full-logs/linux
nproc=$(nproc)
./mach test-wpt \
--bin ${{ inputs.binary-path }} \
$WPT_ALWAYS_SUCCEED_ARG \
--profile ${{ inputs.profile }} --processes $((nproc * ${{ runner.environment == 'self-hosted' && 2 || 1 }})) --timeout-multiplier 2 \
--total-chunks ${{ needs.runner-select.outputs.selected-runner-count }} --this-chunk ${{ matrix.chunk_id }} \
--log-raw wpt-full-logs/linux/raw/${{ matrix.chunk_id }}.log \
--log-wptreport wpt-full-logs/linux/wptreport/${{ matrix.chunk_id }}.json \
--log-raw-stable-unexpected wpt-filtered-logs/linux/${{ matrix.chunk_id }}.log \
--filter-intermittents wpt-filtered-logs/linux/${{ matrix.chunk_id }}.json \
${{ inputs.wpt-args }}
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
- name: Archive results (filtered)
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-filtered-logs-linux-${{ matrix.chunk_id }}
path: wpt-filtered-logs/*/
if-no-files-found: error
- name: Archive results (full)
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-full-logs-linux-${{ matrix.chunk_id }}
path: wpt-full-logs/*/
if-no-files-found: error
report-test-results:
name: Process WPT Results
runs-on: ubuntu-latest
if: ${{ always() }}
needs: linux-wpt
steps:
- name: Merge logs (full)
uses: actions/upload-artifact/merge@v7
with:
name: wpt-full-logs-linux
pattern: wpt-full-logs-linux-*
delete-merged: true
# This job needs to be last. If no filtered results were uploaded, it will fail, but we want to merge other archives in that case.
- name: Merge logs (filtered)
uses: actions/upload-artifact/merge@v7
with:
name: wpt-filtered-logs-linux
pattern: wpt-filtered-logs-linux-*
delete-merged: true
- uses: servo/ci-runners/actions/checkout@a05e7e830e3f4d4c71bdc5a38f003f052b72668c
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
- uses: actions/download-artifact@v8
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
with:
name: wpt-filtered-logs-linux
path: results
- name: Aggregate results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
run: |
touch stable-unexpected-results.log
cat results/linux/*.log > stable-unexpected-results.log || true
- name: Upload aggregated results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
uses: actions/upload-artifact@v7
with:
name: stable-unexpected-results-linux
path: stable-unexpected-results.log
if-no-files-found: error
- name: Report results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
run: |
etc/ci/report_aggregated_expected_results.py \
--tag="linux-wpt" \
results/linux/*.json
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RESULTS: ${{ toJson(needs.*.result) }}