Dflow-0.0.1: test/Main.hs
module Main where
import ArbTest
import Test.Framework
import Test.Framework.Providers.QuickCheck2 (testProperty)
longTest :: TestOptions
longTest = TestOptions Nothing (Just 1000) Nothing Nothing Nothing
main :: IO ()
main = defaultMain tests
tests :: [Test]
tests = map (longTest `plusTestOptions`)
[testGroup "Arbitrary RTSP list equivalence"
[testProperty "compile == interpret" prop_RTSP,
testProperty "ifThenElse definition" prop_rtspIfThenElse
],
testGroup "Event order consistency"
[testProperty "emitsBefore consistent with isBefore" prop_emitsBefore
],
testGroup "Monoid laws, plus commutivity"
[testProperty "Monoid left identity" prop_rtspMonoid1,
testProperty "Monoid right identity" prop_rtspMonoid2,
testProperty "Monoid commutes" prop_rtspMonoidCommutes,
testProperty "Monoid associates" prop_rtspMonoidAssociates
],
testGroup "Category laws"
[testProperty "Category left identity" prop_rtspCategoryId1,
testProperty "Category right identity" prop_rtspCategoryId2,
testProperty "Category associates" prop_rtspCategoryAssociates,
testProperty "Category associates 2" prop_rtspCategoryAssociates2
],
testGroup "Sample RTAs"
[
testProperty "Event Count" prop_eventCount,
testProperty "Event Latch" prop_eventLatch
]
]