Commit d1b475bc authored by Steffen Michels's avatar Steffen Michels

fixed behaviour of \/: show failed assertions on both sides

parent e7a76960
......@@ -75,15 +75,15 @@ instance \/ Bool Bool where (\/) x y = prop (x || y)
instance \/ Property Bool where (\/) x y = x \/ prop y
instance \/ Bool Property where (\/) x y = prop x \/ y
instance \/ Property Property
where (\/) x y = Prop (or x y)
where
or x y genState r
= case testAnalysis r (evaluate x genState r) of
r=:{res=OK} = [r]
r=:{res=Pass} = case testAnalysis r (evaluate y genState r) of
where
(\/) x y = Prop (or x y)
where
or x y genState r = case testAnalysis r (evaluate x genState r) of
r=:{res=OK} -> [r]
r=:{res=Pass} -> case testAnalysis r (evaluate y genState r) of
r2=:{res=OK} = [r2]
= [r]
= evaluate y genState r
r -> evaluate y genState r
(<==>) infix 1 :: !a !b -> Property | Testable a & Testable b // True if properties are equivalent
(<==>) p q
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment