module Main where import System.Environment (getArgs) import Test.MuCheck (mucheck) import Test.MuCheck.TestAdapter.QuickCheck import Test.MuCheck.TestAdapter import Test.MuCheck.Utils.Print main :: IO () main = do val <- getArgs case val of ("-h" : _ ) -> help (fn : file : args) -> do (msum, _tsum) <- mucheck tsFn fn file args putStrLn (show msum) _ -> error "Need function file [args]\n\tUse -h to get help" where tsFn :: Mutant -> TestStr -> InterpreterOutput QuickCheckSummary -> Summary tsFn = testSummary help :: IO () help = putStrLn $ "mucheck function file [args]\n" ++ showAS ["E.g:", " mucheck-quickcheck qsort Examples/QuickCheckTest.hs 'quickCheckResult idEmpProp' 'quickCheckResult revProp' 'quickCheckResult modelProp'",""]