MapMutator clamps the given min and max values:
|
this.minSize = Math.max(minSize, DEFAULT_MIN_SIZE); |
|
this.maxSize = Math.min(maxSize, DEFAULT_MAX_SIZE); |
This seems to differ from the other mutators such as ListMutator or ArrayMutator which use the given min and max values as is, and instead only perform validation using require(...).
Is it intended that MapMutator differs here in behavior? For consistency, would it make sense to use require here as well to impose restrictions (at least for the minSize)?
MapMutatorclamps the given min and max values:jazzer/src/main/java/com/code_intelligence/jazzer/mutation/mutator/collection/MapMutatorFactory.java
Lines 99 to 100 in e13aef0
This seems to differ from the other mutators such as
ListMutatororArrayMutatorwhich use the given min and max values as is, and instead only perform validation usingrequire(...).Is it intended that
MapMutatordiffers here in behavior? For consistency, would it make sense to userequirehere as well to impose restrictions (at least for theminSize)?