Merge pull request #196 from BoltzExchange/harden-scripts #803
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: [push, pull_request] | |
| jobs: | |
| build: | |
| strategy: | |
| matrix: | |
| platform: [ubuntu-latest] | |
| node-version: [20, 22, 24, 25, 26] | |
| runs-on: ${{ matrix.platform }} | |
| steps: | |
| - name: Use Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| - name: Install Foundry | |
| uses: foundry-rs/foundry-toolchain@v1 | |
| - name: Check out code | |
| uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Start regtest containers | |
| run: npm run docker:start | |
| - name: Compile | |
| run: npm run compile | |
| - name: Lint | |
| run: npm run lint | |
| - name: Prettier | |
| run: npm run prettier:check | |
| - name: Forge lint | |
| run: forge clean && forge lint --severity gas --no-cache --deny notes | |
| - name: Forge fmt | |
| run: forge fmt --check | |
| - name: Unit tests | |
| run: npm run test:unit | |
| - name: Integration tests | |
| run: npm run test:int | |
| - name: Contract tests | |
| run: forge clean && npm run test:solidity | |
| build-bun: | |
| strategy: | |
| matrix: | |
| platform: [ubuntu-latest] | |
| bun-version: [1.3] | |
| runs-on: ${{ matrix.platform }} | |
| steps: | |
| - name: Use Bun ${{ matrix.bun-version }} | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: ${{ matrix.bun-version }} | |
| - name: Use Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: 24 | |
| - name: Install Foundry | |
| uses: foundry-rs/foundry-toolchain@v1 | |
| - name: Check out code | |
| uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Start regtest containers | |
| run: bun --bun run docker:start | |
| - name: Compile | |
| run: bun --bun run compile | |
| - name: Unit tests | |
| run: bun --bun run test:unit:bun | |
| - name: Integration tests | |
| run: bun --bun run test:int:bun |