You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.3 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. on:
  2. push:
  3. branches:
  4. - master
  5. pull_request:
  6. name: Tests
  7. jobs:
  8. tests:
  9. runs-on: ubuntu-latest
  10. steps:
  11. - name: Checkout sources
  12. uses: actions/checkout@v2
  13. - name: Install stable toolchain
  14. uses: actions-rs/toolchain@v1
  15. with:
  16. profile: minimal
  17. toolchain: 1.74.0
  18. override: true
  19. # Install for Anvil
  20. - name: Install Foundry
  21. uses: foundry-rs/foundry-toolchain@v1
  22. with:
  23. version: nightly
  24. - uses: Swatinem/rust-cache@v1
  25. with:
  26. cache-on-failure: true
  27. - name: cargo test
  28. run: |
  29. export PATH=$HOME/bin:$PATH
  30. cargo test
  31. - name: cargo test circom 2 feature flag
  32. run: |
  33. export PATH=$HOME/bin:$PATH
  34. cargo test --features circom-2
  35. lint:
  36. runs-on: ubuntu-latest
  37. steps:
  38. - name: Checkout sources
  39. uses: actions/checkout@v2
  40. - name: Install stable toolchain
  41. uses: actions-rs/toolchain@v1
  42. with:
  43. profile: minimal
  44. toolchain: 1.74.0
  45. override: true
  46. components: rustfmt, clippy
  47. - name: cargo fmt
  48. run: cargo fmt --all -- --check
  49. - name: cargo clippy
  50. run: cargo clippy -- -D warnings