Wouldn't it be great if we could automatically create generators for a pattern and then be able to exercise them automatically?
There are some patterns that we couldn't do this for e.g. (m/pred my-custom-pred-with-no-generator ?x). But thanks to spec allowing generators on preds we should be able to handle those if they have a generator defined. It would be fantastic to automatically see the sorts of data the pattern can match.
Given that this functionality is really not part of doing the matching, we can also use the full power of meander to create these generators, which could be a fun use case.
Wouldn't it be great if we could automatically create generators for a pattern and then be able to exercise them automatically?
There are some patterns that we couldn't do this for e.g.
(m/pred my-custom-pred-with-no-generator ?x)
. But thanks to spec allowing generators on preds we should be able to handle those if they have a generator defined. It would be fantastic to automatically see the sorts of data the pattern can match.Given that this functionality is really not part of doing the matching, we can also use the full power of meander to create these generators, which could be a fun use case.
Example: