gnark
gnark copied to clipboard
feat: add NoFuzzing() testing option
The new testing option allows to run assertions on test.Assert
without fuzzing. My use case for running tests without fuzzing is in gadget where some errors panic to simplify the API.
Additionally, I was not sure if we should omit fuzzing when the tests are run in short mode? Should we?
maybe it shouldn't be ran actually with "PRoverSucceeded" call. The point of this method is to test constraint system solver against the big.Int test engine -> if a witness fails/succeeds with one, it should with the others.
What about just calling that separately on our integration tests?
Yup, removing fuzz testing in ProverSucceeded
and then fuzzing separately in integration tests makes sense.
On a similar note -- maybe also remove marshalling tests from ProverSucceeded
and move them into a new method? And add assert.AllTests
etc. method for doing marshalling, compiling/solving, fuzzing etc.
(converted to draft until figuring what direction to take)
@gbotrel, do you have suggestion what to do with this PR? Someone stumbled against a similar problem why this PR was created (#336).