arnaucube
arnaucube/circom-compatPublic Self-hosted repository
circom-compat/.github/workflows/ci.yml
.github/workflows/ci.ymlRaw
 1on: [pull_request, push]
 2
 3name: Tests
 4
 5jobs:
 6  tests:
 7    runs-on: ubuntu-latest
 8    steps:
 9      - name: Checkout sources
10        uses: actions/checkout@v2
11      - name: Install stable toolchain
12        uses: actions-rs/toolchain@v1
13        with:
14          profile: minimal
15          toolchain: stable
16          override: true
17
18      - name: Install node
19        uses: actions/setup-node@v1
20        with:
21          node-version: 10
22
23      - name: Install ganache
24        run: npm install -g ganache-cli
25
26      - name: Install Solc
27        run: |
28            mkdir -p "$HOME/bin"
29            wget -q https://github.com/ethereum/solidity/releases/download/v0.7.6/solc-static-linux -O $HOME/bin/solc
30            chmod u+x "$HOME/bin/solc"
31            export PATH=$HOME/bin:$PATH
32            solc --version            
33
34      - name: cargo test
35        run: |
36            export PATH=$HOME/bin:$PATH
37            cargo test            
38
39  lint:
40    runs-on: ubuntu-latest
41    steps:
42      - name: Checkout sources
43        uses: actions/checkout@v2
44      - name: Install stable toolchain
45        uses: actions-rs/toolchain@v1
46        with:
47          profile: minimal
48          toolchain: stable
49          override: true
50          components: rustfmt, clippy
51      - name: cargo fmt
52        run: cargo fmt --all -- --check
53      - name: cargo clippy
54        run: cargo clippy -- -D warnings