From 4aefd0dd15872d5ff3e96707fa5576ae43b50580 Mon Sep 17 00:00:00 2001 From: ChefMist <133624774+ChefMist@users.noreply.github.com> Date: Fri, 14 Feb 2025 09:21:53 +0800 Subject: [PATCH 1/2] feat: remove coverage from ci as breaking build --- .github/workflows/coverage.yml | 67 ---------------------------------- 1 file changed, 67 deletions(-) delete mode 100644 .github/workflows/coverage.yml diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml deleted file mode 100644 index b104942..0000000 --- a/.github/workflows/coverage.yml +++ /dev/null @@ -1,67 +0,0 @@ -name: coverage - -on: - pull_request: - -jobs: - forge-coverage-comment: - name: Forge coverage and comment - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - submodules: recursive - - - name: Install Foundry - uses: foundry-rs/foundry-toolchain@v1 - with: - version: stable - - # install dependency - - uses: actions/setup-node@v3 - with: - node-version: 16 - cache: 'yarn' - - - run: yarn - - # ignore test, script and total line - - name: Run forge coverage - id: coverage - run: | - { - echo 'COVERAGE<> "$GITHUB_OUTPUT" - - # 41898282 is github-actions bot id: https://github.com/marketplace/actions/bot-details - - name: Comment forge coverage report on PR - id: comment - uses: actions/github-script@v5 - with: - script: | - const {data: comments} = await github.rest.issues.listComments({ - owner: context.repo.owner, - repo: context.repo.repo, - issue_number: context.issue.number, - }) - - const botComment = comments.find(comment => comment.user.id === 41898282) - const coverageReport = `${{ steps.coverage.outputs.COVERAGE }}`; - - if (botComment) { - github.rest.issues.updateComment({ - owner: context.repo.owner, - repo: context.repo.repo, - comment_id: botComment.id, - body: coverageReport - }) - } else { - github.rest.issues.createComment({ - issue_number: context.issue.number, - owner: context.repo.owner, - repo: context.repo.repo, - body: coverageReport - }); - } From 1a4e99e9899f7c8ee976c5274aa8d7c62db6fd04 Mon Sep 17 00:00:00 2001 From: ChefMist <133624774+ChefMist@users.noreply.github.com> Date: Fri, 14 Feb 2025 09:22:15 +0800 Subject: [PATCH 2/2] feat: follow periphery and set 5 runs for local --- foundry.toml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/foundry.toml b/foundry.toml index 9863e10..bede874 100644 --- a/foundry.toml +++ b/foundry.toml @@ -17,9 +17,7 @@ gas_limit = "300000000" bytecode_hash = "none" [fuzz] -# used for both fuzz and invariant tests for local development -# not sure why but [profile.default.fuzz] just doesn't work for invariant tests -runs = 1000 +runs = 5 # change this for higher number of fuzz runs locally [profile.ci.fuzz] runs = 10000