quickcheck-monoid-subclasses-0.3.0.3: Testing monoid subclass instances with QuickCheck
Copyright© 2022–2024 Jonathan Knowles
LicenseApache-2.0
Safe HaskellNone
LanguageHaskell2010

Test.QuickCheck.Classes.Monoid.Null

Contents

Description

This module provides Laws definitions for classes exported by Data.Monoid.Null.

Synopsis

Null

monoidNullLaws :: (Arbitrary a, Show a, Eq a, MonoidNull a) => Proxy a -> Laws Source #

Laws for instances of MonoidNull.

Includes the following law:

null a == (a == mempty)

Note that the following superclass laws are not included:

Positive

positiveMonoidLaws :: (Arbitrary a, Show a, Eq a, PositiveMonoid a) => Proxy a -> Laws Source #

Laws for instances of PositiveMonoid.

Includes the following law:

null (a <> b) == (null a && null b)

Note that the following superclass laws are not included: