~jojo/Carth

ref: 3f71c019bc3fd13360c650cd69e5e211660db158 Carth/test/ParseSpec.hs -rw-r--r-- 325 bytes
3f71c019JoJo Delay StartNotDefined error until after typechecking 1 year, 10 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{-# LANGUAGE NumDecimals #-}

module ParseSpec where

import Test.Hspec
import Test.QuickCheck

import Misc
import Ast
import Parse
import Arbitrary


spec :: Spec
spec = do
    describe "parse" $ it "is the inverse of pretty" $ withMaxSuccess
        1e4
        (\progAst -> parse "spec" (pretty progAst) == Right progAst)