module Test where import Generics.Putlenses.Putlens import Generics.Putlenses.Language import Generics.Putlenses.TH import Generics.Putlenses.Examples.Examples import Generics.Putlenses.Examples.People import Generics.Putlenses.QuickCheck import GHC.InOut import Test.QuickCheck prop_mss = wbPartial getDom putDom (put2lens mssPut) getDom s = True -- any source list putDom [] v = v==0 -- when the source is empty we cannot modify the view putDom xs v = v >= 0 -- the updated sum must be at least 0 testMss = quickCheckWith (stdArgs { maxSuccess = 1000 }) prop_mss