Skip to content

Commit cc8ce35

Browse files
Run GUI tests as a separate testsuite
1 parent 2a13ca2 commit cc8ce35

File tree

2 files changed

+17
-12
lines changed

2 files changed

+17
-12
lines changed

.github/workflows/main.yml

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,6 @@ jobs:
5050
- uses: actions/checkout@v4
5151
- name: Install Rust
5252
run: bash ci/install-rust.sh ${{ matrix.rust }} ${{ matrix.target }}
53-
- name: Install npm
54-
if: matrix.os != 'windows-latest'
55-
uses: actions/setup-node@v3
56-
with:
57-
node-version: 20
58-
- name: Install browser-ui-test
59-
if: matrix.os != 'windows-latest'
60-
run: npm install browser-ui-test@"${BROWSER_UI_TEST_VERSION}"
61-
- name: Build and run tests (+ GUI)
62-
if: matrix.os != 'windows-latest'
63-
run: cargo test --locked --target ${{ matrix.target }} --test gui
6453
- name: Build and run tests
6554
run: cargo test --locked --target ${{ matrix.target }}
6655
- name: Test no default
@@ -84,6 +73,22 @@ jobs:
8473
run: rustup update stable && rustup default stable && rustup component add rustfmt
8574
- run: cargo fmt --check
8675

76+
gui:
77+
name: GUI tests
78+
runs-on: ubuntu-latest
79+
steps:
80+
- uses: actions/checkout@v4
81+
- name: Install Rust
82+
run: bash ci/install-rust.sh stable x86_64-unknown-linux-gnu
83+
- name: Install npm
84+
uses: actions/setup-node@v3
85+
with:
86+
node-version: 20
87+
- name: Install browser-ui-test
88+
run: npm install browser-ui-test@"${BROWSER_UI_TEST_VERSION}"
89+
- name: Build and run tests (+ GUI)
90+
run: cargo test --locked --target x86_64-unknown-linux-gnu --test gui
91+
8792
# The success job is here to consolidate the total success/failure state of
8893
# all other jobs. This job is then included in the GitHub branch protection
8994
# rule which prevents merges unless all other jobs are passing. This makes

tests/gui/runner.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,5 +83,5 @@ fn main() {
8383

8484
// Then we run the GUI tests on it.
8585
let status = command.status().expect("failed to get command output");
86-
assert!(status.success());
86+
assert!(status.success(), "{status:?}");
8787
}

0 commit comments

Comments
 (0)