Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
wine-mirror
GitHub Repository: wine-mirror/wine
Path: blob/master/tools/gitlab/test.yml
8577 views
1
# CI script for testing Wine
2
3
.wine-test:
4
stage: test
5
image: $CI_REGISTRY/wine/wine:debian-trixie
6
interruptible: true
7
variables:
8
GIT_STRATEGY: none
9
GECKO_VER: 2.47.4
10
MONO_VER: 10.4.1
11
cache:
12
- key: wine-gecko-$GECKO_VER
13
paths:
14
- wine-gecko-$GECKO_VER-x86.msi
15
- wine-gecko-$GECKO_VER-x86_64.msi
16
- key: wine-mono-$MONO_VER
17
paths:
18
- wine-mono-$MONO_VER-x86.msi
19
before_script:
20
- |
21
printf '\e[0Ksection_start:%s:wine_test_prepare_env[collapsed=true]\r\e[0K' "$(date +%s)"
22
printf '\e[36;1mPreparing environment for Wine\e[0m\n'
23
- export BASEDIR=$PWD
24
- export PATH=$BASEDIR/usr/local/bin:$PATH
25
- export DISPLAY=:0
26
- export LC_ALL=C.UTF-8
27
- export LP_NUM_THREADS=4
28
- export WINEDEBUG=err-all,fixme-all
29
- |
30
cat >$HOME/xorg.conf << EOF
31
Section "Device"
32
Identifier "dummy"
33
Driver "dummy"
34
VideoRam 32768
35
EndSection
36
EOF
37
- echo 'exec /usr/bin/fvwm -f config -c "Style * MwmDecor" -c "Style * UsePPosition" 2>/dev/null' >$HOME/.xinitrc
38
- startx -- -config $HOME/xorg.conf $DISPLAY & while ! pgrep fvwm >/dev/null 2>&1; do sleep 1; done
39
- test -f wine-gecko-$GECKO_VER-x86.msi || curl -o wine-gecko-$GECKO_VER-x86.msi https://dl.winehq.org/wine/wine-gecko/$GECKO_VER/wine-gecko-$GECKO_VER-x86.msi
40
- test -f wine-gecko-$GECKO_VER-x86_64.msi || curl -o wine-gecko-$GECKO_VER-x86_64.msi https://dl.winehq.org/wine/wine-gecko/$GECKO_VER/wine-gecko-$GECKO_VER-x86_64.msi
41
- test -f wine-mono-$MONO_VER-x86.msi || curl -o wine-mono-$MONO_VER-x86.msi https://dl.winehq.org/wine/wine-mono/$MONO_VER/wine-mono-$MONO_VER-x86.msi
42
- mkdir -p $HOME/Documents $HOME/Desktop usr/local/share/wine/gecko usr/local/share/wine/mono
43
- ln -sf $BASEDIR/wine-gecko-$GECKO_VER-x86.msi $BASEDIR/wine-gecko-$GECKO_VER-x86_64.msi usr/local/share/wine/gecko
44
- ln -sf $BASEDIR/wine-mono-$MONO_VER-x86.msi usr/local/share/wine/mono
45
- pulseaudio --start --exit-idle-time=-1
46
- wine wineboot.exe -u
47
- wineserver -w
48
- printf '\e[0Ksection_end:%s:wine_test_prepare_env\r\e[0K' "$(date +%s)"
49
50
.wine-test-windows:
51
stage: test
52
interruptible: true
53
variables:
54
GIT_STRATEGY: none
55
# Non-ascii characters in authors name may get into the output of kernel32:process test which cause
56
# qemu-agent.py in Windows to fail with: UnicodeDecodeError: 'utf-8' codec can't decode byte ...
57
CI_COMMIT_AUTHOR: ""
58
CI_COMMIT_DESCRIPTION: ""
59
CI_COMMIT_MESSAGE: ""
60
GITLAB_USER_NAME: ""
61
62
test-linux-64:
63
extends: .wine-test
64
variables:
65
INCLUDE_TESTS: "dinput ntoskrnl.exe"
66
rules:
67
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
68
needs:
69
- job: build-linux
70
script:
71
- export WINETEST_COLOR=1
72
- wine usr/local/lib/wine/x86_64-windows/winetest.exe -q -q -o - -J winetest.xml $INCLUDE_TESTS
73
artifacts:
74
when: always
75
paths:
76
- winetest.xml
77
reports:
78
junit: winetest.xml
79
80
test-linux-32:
81
extends: .wine-test
82
rules:
83
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
84
needs:
85
- job: build-linux
86
script:
87
- export WINETEST_COLOR=1
88
- wine usr/local/lib/wine/i386-windows/winetest.exe -q -q -o - -J winetest.xml
89
artifacts:
90
when: always
91
paths:
92
- winetest.xml
93
reports:
94
junit: winetest.xml
95
96
test-win10-21h2-32:
97
extends: .wine-test-windows
98
rules:
99
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
100
needs:
101
- job: build-winetest
102
tags:
103
- win10-21h2
104
script:
105
- $WINETEST_ARGS = @(Get-Content ./winetest.args)
106
- |
107
if ($WINETEST_ARGS.count -gt 0) {
108
./winetest.exe -q -q -o - -J winetest.tmp @WINETEST_ARGS >winetest.log
109
} else {
110
echo '<?xml version="1.0" encoding="UTF-8"?><testsuites/>' >winetest.tmp
111
echo $null >winetest.log
112
}
113
after_script:
114
- Get-Content ./winetest.tmp | Set-Content -Encoding utf8 winetest.xml
115
- Get-Content ./winetest.log
116
artifacts:
117
when: always
118
paths:
119
- winetest.xml
120
- winetest.log
121
reports:
122
junit: winetest.xml
123
124
test-win10-21h2-64:
125
extends: .wine-test-windows
126
rules:
127
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
128
needs:
129
- job: build-winetest
130
tags:
131
- win10-21h2
132
script:
133
- $WINETEST_ARGS = @(Get-Content ./winetest.args)
134
- |
135
if ($WINETEST_ARGS.count -gt 0) {
136
./winetest64.exe -q -q -o - -J winetest.tmp @WINETEST_ARGS >winetest.log
137
} else {
138
echo '<?xml version="1.0" encoding="UTF-8"?><testsuites/>' >winetest.tmp
139
echo $null >winetest.log
140
}
141
after_script:
142
- Get-Content ./winetest.tmp | Set-Content -Encoding utf8 winetest.xml
143
- Get-Content ./winetest.log
144
artifacts:
145
when: always
146
paths:
147
- winetest.xml
148
- winetest.log
149
reports:
150
junit: winetest.xml
151
152
debian-32:
153
extends: .wine-test
154
rules:
155
- if: $CI_PIPELINE_SOURCE == 'trigger' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
156
needs:
157
- job: build-daily-linux
158
script:
159
- wine usr/local/lib/wine/i386-windows/winetest.exe -q
160
161
debian-wow64:
162
extends: debian-32
163
variables:
164
WINEARCH: "wow64"
165
166
debian-64:
167
extends: .wine-test
168
rules:
169
- if: $CI_PIPELINE_SOURCE == 'trigger' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
170
needs:
171
- job: build-daily-linux
172
script:
173
- wine usr/local/lib/wine/x86_64-windows/winetest.exe -q
174
175
win10-21h2-32:
176
extends: .wine-test-windows
177
rules:
178
- if: $CI_PIPELINE_SOURCE == 'trigger' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
179
needs:
180
- job: build-daily-winetest
181
tags:
182
- win10-21h2
183
script:
184
- ./winetest.exe -q
185
186
win10-21h2-64:
187
extends: .wine-test-windows
188
rules:
189
- if: $CI_PIPELINE_SOURCE == 'trigger' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
190
needs:
191
- job: build-daily-winetest
192
tags:
193
- win10-21h2
194
script:
195
- ./winetest64.exe -q
196
197