ci-aptos-contract.yml 987 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. on:
  2. pull_request:
  3. paths:
  4. - .github/workflows/ci-aptos-contract.yml
  5. - target_chains/aptos/contracts/**
  6. push:
  7. branches:
  8. - main
  9. name: Aptos Contract
  10. jobs:
  11. aptos-tests:
  12. name: Aptos tests
  13. runs-on: ubuntu-latest
  14. defaults:
  15. run:
  16. working-directory: target_chains/aptos/contracts/
  17. steps:
  18. - uses: actions/checkout@v3
  19. - name: Download CLI
  20. run: wget https://github.com/aptos-labs/aptos-core/releases/download/aptos-cli-v6.1.1/aptos-cli-6.1.1-Ubuntu-22.04-x86_64.zip
  21. - name: Unzip CLI
  22. run: unzip aptos-cli-6.1.1-Ubuntu-22.04-x86_64.zip
  23. - name: Install movefmt
  24. run: ./aptos update movefmt
  25. - name: Check Formatting
  26. run: ./aptos move fmt
  27. if: success() || failure()
  28. - name: Lint
  29. run: ./aptos move lint --check-test-code --dev
  30. if: success() || failure()
  31. - name: Run tests
  32. run: ./aptos move test
  33. if: success() || failure()