kowainik / prolens

👓 Profunctor based lightweight implementation of Lenses
Mozilla Public License 2.0
74 stars 4 forks source link

Refactor laws tests #44

Closed chshersh closed 3 years ago

chshersh commented 3 years ago

Implement general functions for laws property-testing to avoid code duplication. Ideally, the calls to laws should look like this:

lawsSpecs :: Spec
lawsSpecs = describe "Laws" $ do
    describe "Profunctor" $ do
        profunctorLaws "->"     genFunction (===)
        profunctorLaws "Fun"    genFun      eqFun
        profunctorLaws "Forget" genForget   eqForget
vrom911 commented 3 years ago

Resolved in #45