Skip to content

Commit 54ca5ae

Browse files
committed
feat: Add initial build and test.
1 parent 7c11f3c commit 54ca5ae

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Build And Test
2+
3+
on: [push]
4+
5+
env:
6+
CARGO_TERM_COLOR: always
7+
CARGOFLAGS: --workspace --all-targets --all-features --release
8+
9+
jobs:
10+
build:
11+
name: Compile code
12+
runs-on: ubicloud-standard-30
13+
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- name: Save build artifacts
18+
uses: Swatinem/rust-cache@v2
19+
with:
20+
shared-key: "build"
21+
22+
- name: Compile
23+
run: cargo build $CARGOFLAGS --verbose
24+
25+
test:
26+
name: Test code
27+
runs-on: ubicloud-standard-30
28+
needs: build
29+
30+
steps:
31+
- uses: actions/checkout@v4
32+
33+
- name: Restore cached build artifacts
34+
uses: Swatinem/rust-cache@v2
35+
with:
36+
shared-key: "build"
37+
38+
- name: Run tests
39+
run: cargo test $CARGOFLAGS

0 commit comments

Comments
 (0)