Skip to content

Commit 88bffb4

Browse files
committed
make manual flows optional
1 parent da213b8 commit 88bffb4

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

.github/workflows/smoke.yml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,15 @@ on:
1818
inputs:
1919
win_installer_link:
2020
description: 'The link to the Windows installer (win64) for the Fx under test'
21-
required: true
21+
required: false
2222
type: string
2323
mac_installer_link:
2424
description: 'The link to the macOS installer for the Fx under test'
25-
required: true
25+
required: false
2626
type: string
2727
linux_tarball_link:
2828
description: 'The link to the Linux tarball (linux-x86_64) for the Fx under test'
29-
required: true
29+
required: false
3030
type: string
3131
env:
3232
FX_CHANNEL: ${{ inputs.channel }}
@@ -37,7 +37,7 @@ env:
3737

3838
jobs:
3939
Smoke-Windows:
40-
if: ${{ inputs.job_to_run == 'Smoke-Windows' || github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' }}
40+
if: ${{ inputs.job_to_run == 'Smoke-Windows' || github.event_name == 'pull_request' || inputs.win_installer_link }}
4141
runs-on: windows-latest
4242
steps:
4343
- name: Create app token
@@ -146,7 +146,7 @@ jobs:
146146
name: artifacts-win
147147
path: artifacts-win
148148
Smoke-MacOS:
149-
if: ${{ inputs.job_to_run == 'Smoke-MacOS' || github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' }}
149+
if: ${{ inputs.job_to_run == 'Smoke-MacOS' || github.event_name == 'pull_request' || inputs.mac_installer_link }}
150150
runs-on: macos-latest
151151
steps:
152152
- name: Create app token
@@ -220,7 +220,7 @@ jobs:
220220
name: artifacts-mac
221221
path: artifacts-mac
222222
Smoke-Linux:
223-
if: ${{ github.event_name == 'workflow_dispatch' }}
223+
if: ${{ inputs.linux_tarball_link }}
224224
runs-on: ubuntu-latest
225225
steps:
226226
- name: Create app token
@@ -249,8 +249,8 @@ jobs:
249249
run: |
250250
echo "MANUAL='true'" >> "$GITHUB_ENV";
251251
echo "Running smoke tests on supplied executable";
252+
sudo apt install gnome-screenshot
252253
uname -m;
253-
sudo apt install xvfb;
254254
mkdir -p artifacts;
255255
pip3 install 'pipenv==2023.11.15';
256256
pip3 install 'ruff>=0.4.8,<0.5';
@@ -267,7 +267,8 @@ jobs:
267267
run: |
268268
"$FX_EXECUTABLE" --version
269269
pipenv run python choose_ci_set.py
270-
Xvfb :99 & DISPLAY=:99 pipenv run pytest --fx-executable="$FX_EXECUTABLE" -n 4 $(cat selected_tests) || TEST_EXIT_CODE=$?
270+
Xvfb :99 '1600x1200x24' > ~/artifacts/xvfb/xvfb.log 2>&1
271+
DISPLAY=:99 pipenv run pytest --fx-executable="$FX_EXECUTABLE" -n 4 $(cat selected_tests) || TEST_EXIT_CODE=$?
271272
exit $TEST_EXIT_CODE
272273
- name: Run Smoke Tests in Ubuntu (Headed)
273274
if: steps.setup.conclusion == 'success' && always()
@@ -276,7 +277,7 @@ jobs:
276277
run: |
277278
mv ./ci_pyproject_headed.toml ./pyproject.toml;
278279
pipenv run python choose_ci_set.py
279-
Xvfb :99 & DISPLAY=:99 pipenv run pytest --fx-executable="$FX_EXECUTABLE" $(cat selected_tests) || TEST_EXIT_CODE=$?
280+
DISPLAY=:99 pipenv run pytest --fx-executable="$FX_EXECUTABLE" $(cat selected_tests) || TEST_EXIT_CODE=$?
280281
exit $TEST_EXIT_CODE
281282
282283
Use-Artifacts:

0 commit comments

Comments
 (0)