Skip to content

Commit a0538c1

Browse files
authored
chore: make github workflows work (#10)
* chore: add rust-tests.yml * chore: adjust workflows * chore: add comments why comment out part of tests
1 parent b64acf1 commit a0538c1

File tree

5 files changed

+52
-44
lines changed

5 files changed

+52
-44
lines changed

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ jobs:
2020

2121
# Run tests with all features
2222
- name: Run complete tests
23-
run: cargo test --all-features --doc
23+
run: cargo test --features "default,snapshot_builder,fs_import,url_import,web,os_exit" --doc

.github/workflows/examples.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,9 @@ jobs:
2424
- name: worker_pool
2525
run: cargo run --example worker_pool --features "worker"
2626

27-
- name: web_features
28-
run: cargo run --example web_features --features "web"
27+
## MEMO(ysh): Comment out due to upstream breaking changes
28+
# - name: web_features
29+
# run: cargo run --example web_features --features "web"
2930

3031
- name: url_imports
3132
run: cargo run --example url_import --features="fs_import url_import"
@@ -87,5 +88,6 @@ jobs:
8788
- name: async_eval
8889
run: cargo run --example async_eval
8990

90-
- name: websocket
91-
run: cargo run --example websocket --features="web websocket"
91+
## MEMO(ysh): Comment out due to upstream breaking changes
92+
# - name: websocket
93+
# run: cargo run --example websocket --features="web websocket"

.github/workflows/linter.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ jobs:
3030

3131
# Lint all the things
3232
- name: Run clippy
33-
run: cargo clippy --all-features
33+
run: cargo clippy --features "default,snapshot_builder,fs_import,url_import,web,os_exit"
3434

3535
# Test documentation generation
3636
- name: Test documentation
37-
run: cargo doc --features snapshot_builder
37+
run: cargo doc --features snapshot_builder

.github/workflows/rust-tests.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Rust Tests
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches: [ master ]
7+
pull_request:
8+
types:
9+
- opened
10+
- synchronize
11+
- reopened
12+
13+
env:
14+
CARGO_TERM_COLOR: always
15+
16+
jobs:
17+
test:
18+
name: Run Tests
19+
runs-on: ubuntu-latest
20+
21+
steps:
22+
- name: Checkout code
23+
uses: actions/checkout@v4
24+
25+
- name: Setup Rust toolchain
26+
uses: dtolnay/rust-toolchain@stable
27+
with:
28+
toolchain: 1.88.0
29+
30+
- name: Cache cargo dependencies
31+
uses: Swatinem/rust-cache@v2
32+
33+
- name: Run barebones tests (no features)
34+
run: cargo test --no-default-features --lib
35+
36+
- name: Run default tests
37+
run: cargo test --verbose --lib
38+
39+
- name: Run web tests
40+
run: cargo test --features "web" --lib
41+
42+
- name: Run complete tests (all features)
43+
run: cargo test --features "default,snapshot_builder,fs_import,url_import,web,os_exit" --lib

.github/workflows/tests.yml

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)