Skip to content

Instantly share code, notes, and snippets.

@deque-blog
Created December 31, 2016 15:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deque-blog/5e27313239d75ff1eb036f19398f4be6 to your computer and use it in GitHub Desktop.
Save deque-blog/5e27313239d75ff1eb036f19398f4be6 to your computer and use it in GitHub Desktop.
testCases :: [(Int, String)]
testCases = [ (0, "0"), (1, "1"), (3, "Fizz"), (5, "Buzz")
, (7, "7"), (15, "FizzBuzz"), (100, "Buzz")]
tests :: Test
tests = TestList $ map createTestCase testCases
where
createTestCase (input, expected) =
let label = "FizzBuzz of " ++ show input
in TestCase $ assertEqual label expected (fizzBuzz input)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment