diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 00000000..64fc70cd --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,31 @@ +name: Run Forge Tests + +on: [push, pull_request] + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up Node.js + uses: actions/setup-node@v2 + with: + node-version: '20' + + - name: Install dependencies + run: yarn install --immutable + + - name: Run Forge tests + env: + MAINNET_RPC_URL: ${{ secrets.MAINNET_RPC_URL }} + run: | + forge test --rpc-url $MAINNET_RPC_URL --report report.json + + - name: Upload test report + uses: actions/upload-artifact@v2 + with: + name: forge-test-report + path: report.json \ No newline at end of file