You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Property-based testing is widespread with Haskell projects. They either generate test instances randomly or exhaustively and test that specific properties are satisfied. This is pretty much fuzzing and should be treated as such.
Describe the solution you'd like
QuickCheck, SmallCheck, Hedgehog, and validity are property-based testing frameworks for Haskell that I know of (likely not an exhaustive list).
Detecting their use could be done by scanning for imports of Haskell modules from these Haskell packages in test code, which would be roughly on par with what fuzzing detection for Go does. This can be an entry in languageFuzzSpecs as with Go.
Describe alternatives you've considered
An alternative would be to detect the use of property-based testing Haskell packages in Cabal or hpack files. However, this may have a much higher false positive or false negative rate given the limited matching based on regular expressions that is available. Import statements in Haskell have a much more regular form that would be more easily accommodated with regular expressions.
Pattern matching on specific function declarations will not work because there is no standardized function declaration convention for property-based tests; individual tests may not even be in their own named function.
Additional context
This is basically declaring my intention and willingness to add this detection to fuzzing.go unless the owners think otherwise.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Property-based testing is widespread with Haskell projects. They either generate test instances randomly or exhaustively and test that specific properties are satisfied. This is pretty much fuzzing and should be treated as such.
Describe the solution you'd like
QuickCheck, SmallCheck, Hedgehog, and validity are property-based testing frameworks for Haskell that I know of (likely not an exhaustive list).
Detecting their use could be done by scanning for imports of Haskell modules from these Haskell packages in test code, which would be roughly on par with what fuzzing detection for Go does. This can be an entry in
languageFuzzSpecs
as with Go.Describe alternatives you've considered
An alternative would be to detect the use of property-based testing Haskell packages in Cabal or hpack files. However, this may have a much higher false positive or false negative rate given the limited matching based on regular expressions that is available. Import statements in Haskell have a much more regular form that would be more easily accommodated with regular expressions.
Pattern matching on specific function declarations will not work because there is no standardized function declaration convention for property-based tests; individual tests may not even be in their own named function.
Additional context
This is basically declaring my intention and willingness to add this detection to
fuzzing.go
unless the owners think otherwise.The text was updated successfully, but these errors were encountered: