diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 14039738..7d85388a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: needs: [lint, test] strategy: matrix: - environment: [ubuntu-latest, macos-13, macos-14, windows-latest] + environment: [ubuntu-latest, macos-15-intel, macos-14, windows-latest] permissions: contents: read id-token: write @@ -157,7 +157,7 @@ jobs: test: strategy: matrix: - environment: [ubuntu-latest, macos-13, macos-14, windows-latest] + environment: [ubuntu-latest, macos-15-intel, macos-14, windows-latest] runs-on: ${{ matrix.environment }} timeout-minutes: 20 diff --git a/fuzzing/fuzzer_test.go b/fuzzing/fuzzer_test.go index 017090de..61c7e34e 100644 --- a/fuzzing/fuzzer_test.go +++ b/fuzzing/fuzzer_test.go @@ -764,9 +764,36 @@ func TestValueGenerationSolving(t *testing.T) { "testdata/contracts/value_generation/match_addr_sender.sol", "testdata/contracts/value_generation/match_string_exact.sol", "testdata/contracts/value_generation/match_structs_xy.sol", + "testdata/contracts/value_generation/match_payable_xy.sol", + } + for _, filePath := range filePaths { + runFuzzerTest(t, &fuzzerSolcFileTest{ + filePath: filePath, + configUpdates: func(config *config.ProjectConfig) { + config.Fuzzing.TargetContracts = []string{"TestContract"} + config.Fuzzing.Testing.AssertionTesting.Enabled = false + config.Fuzzing.Testing.OptimizationTesting.Enabled = false + config.Slither.UseSlither = true + }, + method: func(f *fuzzerTestContext) { + // Start the fuzzer + err := f.fuzzer.Start() + assert.NoError(t, err) + + // Check for any failed tests and verify coverage was captured + assertFailedTestsExpected(f, true) + assertCorpusCallSequencesCollected(f, true) + }, + }) + } +} + +// TestComplexValueGenerationSolving runs a series of tests to test the value generator can solve expected problems. +// Specifically, this test provides a much larger test limit since some of these tests fail to get solved in the CI fast enough. +func TestComplexValueGenerationSolving(t *testing.T) { + filePaths := []string{ "testdata/contracts/value_generation/match_ints_xy.sol", "testdata/contracts/value_generation/match_uints_xy.sol", - "testdata/contracts/value_generation/match_payable_xy.sol", } for _, filePath := range filePaths { runFuzzerTest(t, &fuzzerSolcFileTest{ @@ -775,6 +802,7 @@ func TestValueGenerationSolving(t *testing.T) { config.Fuzzing.TargetContracts = []string{"TestContract"} config.Fuzzing.Testing.AssertionTesting.Enabled = false config.Fuzzing.Testing.OptimizationTesting.Enabled = false + config.Fuzzing.TestLimit = 15_000_000 config.Slither.UseSlither = true }, method: func(f *fuzzerTestContext) {