]> gitweb.michael.orlitzky.com - hath.git/blob - test/TestSuite.hs
Use Cabal test integration.
[hath.git] / test / TestSuite.hs
1 {-# LANGUAGE NoMonomorphismRestriction #-}
2 import Data.Monoid (mempty)
3 import Test.Framework (
4 Test,
5 defaultMainWithOpts,
6 )
7 import Test.Framework.Options
8 import Test.Framework.Runners.Options
9
10 import Cidr (cidr_properties, cidr_tests)
11
12 import IPv4Address (ipv4address_tests)
13 import Octet (octet_tests)
14
15 tests :: [Test.Framework.Test]
16 tests = [ cidr_properties,
17 cidr_tests,
18 ipv4address_tests,
19 octet_tests ]
20
21 main :: IO ()
22 main = do
23 let empty_test_opts = mempty :: TestOptions
24 let my_test_opts = empty_test_opts {
25 --
26 -- Increase to 5000 when,
27 -- https://github.com/batterseapower/test-framework/issues/34
28 -- is fixed.
29 --
30 topt_maximum_generated_tests = Just 1000
31 }
32 let empty_runner_opts = mempty :: RunnerOptions
33 let my_runner_opts = empty_runner_opts {
34 ropt_test_options = Just my_test_opts
35 }
36
37 defaultMainWithOpts tests my_runner_opts