Created
September 10, 2013 07:16
-
-
Save nh2/6505995 to your computer and use it in GitHub Desktop.
Haskell Cucumber syntax - an alternative syntax proposed for Haskell along with normal Haskell and Literate Haskell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Feature: The Data.List module | |
In order to be able to use lists | |
As a programmer | |
I want a module that defines list functions | |
Scenario: Defining the function foldl | |
Given I want do define foldl | |
Which has the type (in brackets) a to b to a (end of brackets), to a, to list of b, to a | |
And my arguments are called f, acc, and l | |
When l is empty | |
Then the result better be acc | |
Otherwise l is x cons xs | |
Then the result should be foldl f (in brackets) f acc x (end of brackets) xs |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Good stuff. Need to work on better highlighting though.