lawful-classes-hedgehog-0.1.0.0: Hedgehog support for lawful-classes
Copyright(c) 2023 Nicolas Trangez
LicenseApache-2.0
Maintainerikke@nicolast.be
Stabilityalpha
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Lawful.Hedgehog

Description

Support code to check lawful-classes laws using Hedgehog and, optionally, Tasty.

Synopsis
  • testLaws :: TestName -> (forall a. m a -> PropertyT IO a) -> Laws m -> TestTree
  • toProperty :: (forall a. m a -> PropertyT IO a) -> Law m -> Property

Documentation

testLaws :: TestName -> (forall a. m a -> PropertyT IO a) -> Laws m -> TestTree Source #

Given Laws, create a tasty TestTree.

toProperty :: (forall a. m a -> PropertyT IO a) -> Law m -> Property Source #

Given a way to evaluate an m a into a base Monad, turn a Law into a Property.