Merged
Conversation
bc93823 to
43b5a02
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for Set mutation in the Jazzer mutation framework, mirroring the existing implementations for List and Map.
Key Changes
- Implemented
SetMutatorFactorywith mutation operations (delete, insert, mutate chunks) and crossover operations - Extended
ChunkMutationsandChunkCrossOversutility classes to support Set operations - Added comprehensive test coverage in
SetMutatorTestwith parameterized tests for all operations - Updated
@WithSizeannotation to support Set types alongside List and Map
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| SetMutatorFactory.java | New factory implementing Set mutation with chunk-based operations similar to List/Map mutators |
| CollectionMutators.java | Registered SetMutatorFactory in the list of available mutator factories |
| ChunkMutations.java | Added mutateRandomChunk method for Set with duplicate handling logic |
| ChunkCrossOvers.java | Added insertChunk, overwriteChunk, and crossOverChunk operations for Set |
| WithSize.java | Extended annotation to apply to Set types |
| TestSupport.java | Added utility methods: asSet, isEmpty, getCallerMethodName, and ParameterizedTestUtils.prependArgs |
| SetMutatorTest.java | Comprehensive parameterized tests covering all Set mutation and crossover operations |
| StressTest.java | Added stress test cases for Set types and setSizeInClosedRange helper |
| ArgumentsMutatorFuzzTest.java | Added fuzz tests for Set types and fixed typo in method name |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/main/java/com/code_intelligence/jazzer/mutation/mutator/collection/SetMutatorFactory.java
Outdated
Show resolved
Hide resolved
src/test/java/com/code_intelligence/jazzer/mutation/mutator/StressTest.java
Outdated
Show resolved
Hide resolved
src/test/java/com/code_intelligence/jazzer/mutation/mutator/collection/SetMutatorTest.java
Show resolved
Hide resolved
src/test/java/com/code_intelligence/jazzer/mutation/mutator/collection/SetMutatorTest.java
Show resolved
Hide resolved
selffuzz/src/test/java/com/code_intelligence/selffuzz/mutation/ArgumentsMutatorFuzzTest.java
Show resolved
Hide resolved
selffuzz/src/test/java/com/code_intelligence/selffuzz/mutation/ArgumentsMutatorFuzzTest.java
Show resolved
Hide resolved
43b5a02 to
5f9e596
Compare
simonresch
approved these changes
Nov 4, 2025
Contributor
simonresch
left a comment
There was a problem hiding this comment.
Looks good! Very thorough test cases. 🚀
src/main/java/com/code_intelligence/jazzer/mutation/mutator/collection/SetMutatorFactory.java
Outdated
Show resolved
Hide resolved
5f9e596 to
ccb46bc
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Set mutator to the mutation framework.