From 977495e0faf652e393c93e7af5b5b9f457586a8f Mon Sep 17 00:00:00 2001 From: gabrielstoica Date: Thu, 21 Nov 2024 16:47:54 +0200 Subject: [PATCH] build(tesy.yml): test the optimized contracts without re-compiling them --- .github/workflows/test.yml | 4 ++++ foundry.toml | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7f7d675..2c2feb4 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -34,6 +34,10 @@ jobs: run: "FOUNDRY_PROFILE=optimized forge build" id: build + - name: "Build the test contracts" + run: "FOUNDRY_PROFILE=test-optimized forge build" + id: build-test + - name: "Run the tests" run: "forge test -vvv" id: test diff --git a/foundry.toml b/foundry.toml index b2a9547..3c360c4 100644 --- a/foundry.toml +++ b/foundry.toml @@ -18,6 +18,10 @@ runs = 10_000 out = "out-optimized" via_ir = true +# Test the optimized contracts without re-compiling them +[profile.test-optimized] +src = "test" + [fmt] bracket_spacing = true int_types = "long"