zero-knowledge-gadgets
zero-knowledge-gadgets copied to clipboard
[TASK] Optimize tests for PLONK gadgets
Instead of creating a circuit for each test case for our PLONK gadgets, we should use the following function: https://github.com/ZK-Garage/plonk/blob/master/plonk-core/src/constraint_system/composer.rs#L541
The benefits:
- We could debug in more detail which gate is not satisfying the constraints
- More performant tests -- we dont need to go trough prove/verify process
- Smaller code footprint
NOTE: This should only be done for out gadgets: PoseidonGadget, PathGadget, SetGadget