-
Notifications
You must be signed in to change notification settings - Fork 12
72 lines (59 loc) · 1.88 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: Tests
on:
- push
- pull_request
env:
CARGO_TERM_COLOR: always
jobs:
build-oldest:
name: build oldest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dtolnay/[email protected]
- run: cargo build --verbose --features c-example --manifest-path membrane/Cargo.toml
build-stable:
name: build and test stable
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dtolnay/rust-toolchain@stable
- uses: dart-lang/setup-dart@v1
- name: Update apt
run: sudo apt-get update
- name: Install libclang
run: sudo apt-get install -y libclang-dev
- name: Rust tests
run: cargo test --verbose --features c-example
- name: Rust build workspace
run: cargo build --verbose
- name: Rust build example
working-directory: ./example
run: cargo build --verbose
- name: Rust generate Dart example
working-directory: ./example
run: cargo run
- name: Dart run example
working-directory: ./dart_example
run: |
dart compile exe -D --enable-asserts bin/dart_example.dart
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"$(pwd)/../example/target/debug/"
./bin/dart_example.exe
- name: Compile web
working-directory: ./dart_example
run: dart compile js -o example.js bin/dart_example.dart
- name: Compile on aarch64
uses: uraimo/run-on-arch-action@v2
with:
arch: aarch64
distro: ubuntu22.04
githubToken: ${{ github.token }}
dockerRunArgs: |
--volume "${PWD}:/membrane"
install: |
apt-get update -q -y
apt-get install -q -y curl build-essential git
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
run: |
cd /membrane
~/.cargo/bin/cargo build --config net.git-fetch-with-cli=true