Skip to content

Instantly share code, notes, and snippets.

@jacobstanley
Created November 17, 2016 01:28
Show Gist options
  • Select an option

  • Save jacobstanley/ee5b139b50296e65abffb7365ca8bd31 to your computer and use it in GitHub Desktop.

Select an option

Save jacobstanley/ee5b139b50296e65abffb7365ca8bd31 to your computer and use it in GitHub Desktop.

Revisions

  1. jacobstanley created this gist Nov 17, 2016.
    6 changes: 6 additions & 0 deletions Property.purs
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    prop_foo :: Property ()
    prop_foo = do
    x <- forAll $ elements ["a", "b", "c"]
    y <- forAll $ chooseInt 0 10
    guard $ not (x == "a" && y == 5) -- works like (==>) from QuickCheck
    ..