CoolFace
Datasetpublic

TheRealSamuel/LeetCodeProblem

sourceHugging Faceupdated 2mo agoView on Hugging Face
0likes574downloads
Main.hs28 linesDownload Raw Back to haskell_tests
1 2module Main where3import Test.HUnit4 5--Program start6 7--Program end8 9-- Test cases10 11test1 :: Test12test1 = TestCase (assertEqual "for (haveConflict [ \"01:15 \", \"02:00 \"] [ \"02:00 \", \"03:00 \"])," True (haveConflict ["01:15","02:00"] ["02:00","03:00"]))13 14test2 :: Test15test2 = TestCase (assertEqual "for (haveConflict [ \"01:00 \", \"02:00 \"] [ \"01:20 \", \"03:00 \"])," True (haveConflict ["01:00","02:00"] ["01:20","03:00"]))16 17test3 :: Test18test3 = TestCase (assertEqual "for (haveConflict [ \"10:00 \", \"11:00 \"] [ \"14:00 \", \"15:00 \"])," False (haveConflict ["10:00","11:00"] ["14:00","15:00"]))19 20 21-- Grouping test cases22tests :: Test23tests = TestList [TestLabel "Test1" test1, TestLabel "Test2" test2]24 25-- Running the tests26main :: IO Counts27main = runTestTT tests28 
TheRealSamuel/LeetCodeProblem · CoolFace