smallcheck-lens-0.1: SmallCheck lens laws

Safe HaskellNone
LanguageHaskell2010

Test.Tasty.SmallCheck.Lens.Iso

Synopsis

Documentation

testIso :: (Eq s, Eq a, Show s, Show a, Serial IO a, Serial Identity a, CoSerial IO a, Serial IO s, Serial Identity s, CoSerial IO s) => Iso' s a -> TestTree Source

An Iso' is only legal if the following laws hold:

  1. s ^. l . from l ≡ s
  2. s ^. from l . l ≡ s

An Iso' is also a valid Lens' in both normal and reverse form. Check testLens.