]> gitweb.michael.orlitzky.com - hath.git/blob - test/TestSuite.hs
Allow apply_mask to take a Bit argument that will be used to replace the host bits.
[hath.git] / test / TestSuite.hs
1 import Test.HUnit
2 import Test.QuickCheck.Batch
3
4 import Cidr (cidr_tests,
5 prop_all_cidrs_contain_themselves,
6 prop_contains_proper_intransitive)
7
8 import IPv4Address (ipv4address_tests)
9 import Octet (octet_tests)
10
11 -- The list of HUnit tests.
12 test_suite = TestList (concat [cidr_tests,
13 ipv4address_tests,
14 octet_tests])
15
16 -- QuickCheck options
17 options = TestOptions { no_of_tests = 1000,
18 length_of_tests = 0, -- No time limit on tests.
19 debug_tests = False }
20
21 main :: IO ()
22 main = do
23 putStrLn "HUnit"
24 putStrLn "-----"
25 runTestTT test_suite
26
27 putStrLn ""
28
29 putStrLn "QuickCheck"
30 putStrLn "----------"
31 runTests "Cidr" options [ run prop_all_cidrs_contain_themselves,
32 run prop_contains_proper_intransitive]