Skip to content

Commit 84202a5

Browse files
authored
ci: add job to run batcher tests (#1126)
1 parent fd7b975 commit 84202a5

File tree

1 file changed

+25
-4
lines changed

1 file changed

+25
-4
lines changed
Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: build-rust-projects
1+
name: build-and-test-rust-projects
22

33
on:
44
merge_group:
@@ -7,13 +7,13 @@ on:
77
pull_request:
88
branches: ["*"]
99
paths:
10-
- 'batcher/**'
11-
- '.github/workflows/build-rust.yml'
10+
- "batcher/**"
11+
- ".github/workflows/build-rust.yml"
1212

1313
jobs:
1414
build:
1515
runs-on: aligned-runner
16-
16+
1717
steps:
1818
- uses: actions/checkout@v4
1919

@@ -45,3 +45,24 @@ jobs:
4545
run: |
4646
cd batcher
4747
cargo build --all
48+
49+
test:
50+
runs-on: ubuntu-latest
51+
needs: build
52+
steps:
53+
- name: Checkout code
54+
uses: actions/checkout@v4
55+
- name: Cache Rust dependencies
56+
uses: actions/cache@v3
57+
with:
58+
path: |
59+
~/.cargo/registry
60+
~/.cargo/git
61+
batcher/target
62+
key: ${{ runner.os }}-rust-${{ hashFiles('**/Cargo.lock') }}
63+
restore-keys: |
64+
${{ runner.os }}-rust-
65+
- name: Run tests
66+
run: |
67+
cd batcher
68+
cargo test --all

0 commit comments

Comments
 (0)