Skip to content

Commit 47823c7

Browse files
authored
chore: fix integration tests (#327)
* chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix publishing Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> * chore: fix integration tests Signed-off-by: Stephane Bouchet <[email protected]> --------- Signed-off-by: Stephane Bouchet <[email protected]>
1 parent 07f2ada commit 47823c7

34 files changed

+727
-1835
lines changed

.github/workflows/ci.yml

Lines changed: 354 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,354 @@
1+
# Main CI
2+
name: Java CI with Gradle
3+
4+
on:
5+
push:
6+
branches: [ main ]
7+
pull_request:
8+
branches: [ main ]
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
16+
configure_sonar:
17+
runs-on: ubuntu-latest
18+
if: github.event_name == 'pull_request'
19+
20+
steps:
21+
- name: Save Sonar config on PR
22+
run: |
23+
mkdir -p ./prInfo
24+
echo ${{ github.event.number }} > ./prInfo/PR
25+
echo ${{ github.base_ref }} > ./prInfo/base_ref
26+
echo ${{ github.head_ref }} > ./prInfo/head_ref
27+
- uses: actions/upload-artifact@v4
28+
with:
29+
name: prInfo
30+
path: prInfo/
31+
32+
mainidewindow_idestatusbar_screenshot:
33+
runs-on: ${{ matrix.os }}
34+
strategy:
35+
matrix:
36+
os: [ ubuntu-latest, macos-latest, windows-latest ]
37+
steps:
38+
- uses: actions/checkout@v4
39+
- name: Set up JDK 17
40+
uses: actions/setup-java@v4
41+
with:
42+
java-version: 17
43+
distribution: 'temurin'
44+
cache: 'gradle'
45+
- name: Run integration tests on Linux
46+
run: |
47+
export DISPLAY=:99.0
48+
Xvfb -ac :99 -screen 0 1920x1080x24 &
49+
sleep 10
50+
cd src/test-project
51+
mkdir -p build/reports
52+
chmod +x gradlew
53+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.utils.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.idestatusbar.*
54+
if: runner.os == 'Linux'
55+
- name: Run integration tests on Windows
56+
run: |
57+
cd src\test-project
58+
chmod +x gradlew.bat
59+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.utils.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.mainidewindow.idestatusbar.*
60+
if: runner.os == 'Windows'
61+
- name: Run integration tests on MacOS
62+
run: |
63+
cd src/test-project
64+
chmod +x gradlew
65+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.utils.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.mainidewindow.idestatusbar.*
66+
if: runner.os == 'macOS'
67+
- name: Archiving tests reports
68+
uses: actions/upload-artifact@v4
69+
with:
70+
name: ${{ matrix.os }}-mainidewindow-idestatusbar-test-reports
71+
path: src/test-project/build/reports/tests/*
72+
if: always()
73+
- name: Archiving screenshots
74+
uses: actions/upload-artifact@v4
75+
with:
76+
name: ${{ matrix.os }}-mainidewindow-idestatusbar-screenshots
77+
path: src/test-project/build/screenshots/*
78+
if: always()
79+
- name: Archiving StepLogger logs
80+
uses: actions/upload-artifact@v4
81+
with:
82+
name: ${{ matrix.os }}-mainidewindow-idestatusbar-steplogger-logs
83+
path: src/test-project/build/test-results/*
84+
if: always()
85+
86+
dialogs_information_settings:
87+
runs-on: ${{ matrix.os }}
88+
strategy:
89+
matrix:
90+
os: [ ubuntu-latest, macos-latest, windows-latest ]
91+
steps:
92+
- uses: actions/checkout@v4
93+
- name: Set up JDK 17
94+
uses: actions/setup-java@v4
95+
with:
96+
java-version: 17
97+
distribution: 'temurin'
98+
cache: 'gradle'
99+
- name: Run integration tests on Linux
100+
run: |
101+
export DISPLAY=:99.0
102+
Xvfb -ac :99 -screen 0 1920x1080x24 &
103+
cd src/test-project
104+
chmod +x gradlew
105+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.information.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.settings.*
106+
if: runner.os == 'Linux'
107+
- name: Run integration tests on Windows
108+
run: |
109+
cd src\test-project
110+
chmod +x gradlew.bat
111+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.information.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.settings.*
112+
if: runner.os == 'Windows'
113+
- name: Run integration tests on MacOS
114+
run: |
115+
cd src/test-project
116+
chmod +x gradlew
117+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.information.* --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.settings.*
118+
if: runner.os == 'macOS'
119+
- name: Archiving tests reports
120+
uses: actions/upload-artifact@v4
121+
with:
122+
name: ${{ matrix.os }}-dialogs-information-settings-test-reports
123+
path: src/test-project/build/reports/tests/*
124+
if: always()
125+
- name: Archiving screenshots
126+
uses: actions/upload-artifact@v4
127+
with:
128+
name: ${{ matrix.os }}-dialogs-information-settings-screenshots
129+
path: src/test-project/build/screenshots/*
130+
if: always()
131+
- name: Archiving StepLogger logs
132+
uses: actions/upload-artifact@v4
133+
with:
134+
name: ${{ matrix.os }}-dialogs-information-settings-steplogger-logs
135+
path: src/test-project/build/test-results/*
136+
if: always()
137+
138+
dialogs_project_manipulation:
139+
runs-on: ${{ matrix.os }}
140+
strategy:
141+
matrix:
142+
os: [ ubuntu-latest, macos-latest, windows-latest ]
143+
steps:
144+
- uses: actions/checkout@v4
145+
- name: Set up JDK 11 # Java 11 is only used for test NewProjectDialogTest/setProjectSdkIfAvailableTest
146+
uses: actions/setup-java@v4
147+
with:
148+
java-version: 11
149+
distribution: 'temurin'
150+
cache: 'gradle'
151+
- name: Set up JDK 17
152+
uses: actions/setup-java@v4
153+
with:
154+
java-version: 17
155+
distribution: 'temurin'
156+
cache: 'gradle'
157+
- name: Run integration tests on Linux
158+
run: |
159+
export DISPLAY=:99.0
160+
Xvfb -ac :99 -screen 0 1920x1080x24 &
161+
cd src/test-project
162+
chmod +x gradlew
163+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.project_manipulation.*
164+
if: runner.os == 'Linux'
165+
- name: Run integration tests on Windows
166+
run: |
167+
cd src\test-project
168+
chmod +x gradlew.bat
169+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.project_manipulation.*
170+
if: runner.os == 'Windows'
171+
- name: Run integration tests on MacOS
172+
run: |
173+
cd src/test-project
174+
chmod +x gradlew
175+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.project_manipulation.*
176+
if: runner.os == 'macOS'
177+
- name: Archiving tests reports
178+
uses: actions/upload-artifact@v4
179+
with:
180+
name: ${{ matrix.os }}-dialogs-project-manipulation-test-reports
181+
path: src/test-project/build/reports/tests/*
182+
if: always()
183+
- name: Archiving screenshots
184+
uses: actions/upload-artifact@v4
185+
with:
186+
name: ${{ matrix.os }}-dialogs-project-manipulation-screenshots
187+
path: src/test-project/build/screenshots/*
188+
if: always()
189+
- name: Archiving StepLogger logs
190+
uses: actions/upload-artifact@v4
191+
with:
192+
name: ${{ matrix.os }}-dialogs-project-manipulation-steplogger-logs
193+
path: src/test-project/build/test-results/*
194+
if: always()
195+
196+
dialogs:
197+
runs-on: ${{ matrix.os }}
198+
strategy:
199+
matrix:
200+
os: [ ubuntu-latest, macos-latest, windows-latest ]
201+
202+
steps:
203+
- uses: actions/checkout@v4
204+
- name: Set up JDK 17
205+
uses: actions/setup-java@v4
206+
with:
207+
java-version: 17
208+
distribution: 'temurin'
209+
cache: 'gradle'
210+
- name: Run integration tests on Linux
211+
run: |
212+
export DISPLAY=:99.0
213+
Xvfb -ac :99 -screen 0 1920x1080x24 &
214+
cd src/test-project
215+
chmod +x gradlew
216+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.FlatWelcomeFrameTest
217+
if: runner.os == 'Linux'
218+
- name: Run integration tests on Windows
219+
run: |
220+
cd src\test-project
221+
chmod +x gradlew.bat
222+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.FlatWelcomeFrameTest
223+
if: runner.os == 'Windows'
224+
- name: Run integration tests on MacOS
225+
run: |
226+
cd src/test-project
227+
chmod +x gradlew
228+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.dialogs.FlatWelcomeFrameTest
229+
if: runner.os == 'macOS'
230+
- name: Archiving tests reports
231+
uses: actions/upload-artifact@v4
232+
with:
233+
name: ${{ runner.os }}-dialogs-test-reports
234+
path: src/test-project/build/reports/tests/*
235+
if: always()
236+
- name: Archiving screenshots
237+
uses: actions/upload-artifact@v4
238+
with:
239+
name: ${{ runner.os }}-dialogs-screenshots
240+
path: src/test-project/build/screenshots/*
241+
if: always()
242+
- name: Archiving StepLogger logs
243+
uses: actions/upload-artifact@v4
244+
with:
245+
name: ${{ runner.os }}-dialogs-steplogger-logs
246+
path: src/test-project/build/test-results/*
247+
if: always()
248+
249+
mainidewindow-menubar:
250+
runs-on: ${{ matrix.os }}
251+
strategy:
252+
matrix:
253+
os: [ ubuntu-latest, macos-latest, windows-latest ]
254+
255+
steps:
256+
- uses: actions/checkout@v4
257+
- name: Set up JDK 17
258+
uses: actions/setup-java@v4
259+
with:
260+
java-version: 17
261+
distribution: 'temurin'
262+
cache: 'gradle'
263+
- name: Run integration tests on Linux
264+
run: |
265+
export DISPLAY=:99.0
266+
Xvfb -ac :99 -screen 0 1920x1080x24 &
267+
cd src/test-project
268+
chmod +x gradlew
269+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.menubar.*
270+
if: runner.os == 'Linux'
271+
- name: Run integration tests on Windows
272+
run: |
273+
cd src\test-project
274+
chmod +x gradlew.bat
275+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.menubar.*
276+
if: runner.os == 'Windows'
277+
- name: Run integration tests on MacOS
278+
run: |
279+
cd src/test-project
280+
chmod +x gradlew
281+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.menubar.*
282+
if: runner.os == 'macOS'
283+
- name: Archiving tests reports
284+
uses: actions/upload-artifact@v4
285+
with:
286+
name: ${{ runner.os }}-mainidewindow-menubar-test-reports
287+
path: src/test-project/build/reports/tests/*
288+
if: always()
289+
- name: Archiving screenshots
290+
uses: actions/upload-artifact@v4
291+
with:
292+
name: ${{ runner.os }}-mainidewindow-menubar-screenshots
293+
path: src/test-project/build/screenshots/*
294+
if: always()
295+
- name: Archiving StepLogger logs
296+
uses: actions/upload-artifact@v4
297+
with:
298+
name: ${{ runner.os }}-mainidewindow-menubar-steplogger-logs
299+
path: src/test-project/build/test-results/*
300+
if: always()
301+
302+
303+
mainidewindow-toolwindowspane:
304+
runs-on: ${{ matrix.os }}
305+
strategy:
306+
matrix:
307+
os: [ ubuntu-latest, macos-latest, windows-latest ]
308+
309+
steps:
310+
- uses: actions/checkout@v4
311+
- name: Set up JDK 17
312+
uses: actions/setup-java@v4
313+
with:
314+
java-version: 17
315+
distribution: 'temurin'
316+
cache: 'gradle'
317+
- name: Run integration tests on Linux
318+
run: |
319+
export DISPLAY=:99.0
320+
Xvfb -ac :99 -screen 0 1920x1080x24 &
321+
cd src/test-project
322+
chmod +x gradlew
323+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.toolwindowspane.*
324+
if: runner.os == 'Linux'
325+
- name: Run integration tests on Windows
326+
run: |
327+
cd src\test-project
328+
chmod +x gradlew.bat
329+
.\gradlew.bat integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.toolwindowspane.*
330+
if: runner.os == 'Windows'
331+
- name: Run integration tests on MacOS
332+
run: |
333+
cd src/test-project
334+
chmod +x gradlew
335+
./gradlew integrationUITest --warning-mode none --tests com.redhat.devtools.intellij.commonuitest.fixtures.test.mainidewindow.toolwindowspane.*
336+
if: runner.os == 'macOS'
337+
- name: Archiving tests reports
338+
uses: actions/upload-artifact@v4
339+
with:
340+
name: ${{ runner.os }}-mainidewindow-toolwindowspane-test-reports
341+
path: src/test-project/build/reports/tests/*
342+
if: always()
343+
- name: Archiving screenshots
344+
uses: actions/upload-artifact@v4
345+
with:
346+
name: ${{ runner.os }}-mainidewindow-toolwindowspane-screenshots
347+
path: src/test-project/build/screenshots/*
348+
if: always()
349+
- name: Archiving StepLogger logs
350+
uses: actions/upload-artifact@v4
351+
with:
352+
name: ${{ runner.os }}-mainidewindow-toolwindowspane-steplogger-logs
353+
path: src/test-project/build/test-results/*
354+
if: always()

0 commit comments

Comments
 (0)