arowM/elm-parser-test - version: 1.1.0

for more information visit the package's GitHub page

Package contains the following modules:

elm-parser-test

Build Status

Helper functions to develop/test your own parser using elm/parser. It checks whether the result of parser is backtrackable or not.

run (keyword "import") "imp"
--> (Err _, True)
-- This is equival to `ERR{true}` in the notation of Semantics document.
-- https://github.com/elm/parser/blob/master/semantics.md

run (keyword "import") "import"
--> (Ok (), False)
-- This is equival to `OK{false}`.

run spaces "  "
--> (Ok (), False)

run (backtrackable spaces) "  "
--> (Ok (), True)
-- This is equival to `OK{true}`.