X-Git-Url: http://git.megacz.com/?p=sbp.git;a=blobdiff_plain;f=tests%2Ftestcase.g;h=2491600ea0eb3e8536accef2298615ea5dec7fc8;hp=99a7925cdeb6930ede170ca31b1988451fa65955;hb=d2fc6f76cce121e8f6c35af5c733c4269829f82c;hpb=52a970200c90043c7e99a77f29ea85f32753e804 diff --git a/tests/testcase.g b/tests/testcase.g index 99a7925..2491600 100644 --- a/tests/testcase.g +++ b/tests/testcase.g @@ -1,7 +1,9 @@ -ts ::= ws tests ws => ts -tests ::= test %% ws -ws !::= w* -test ::= ^"testcase" "{" input output +/ ws grammar "}" /ws - | ^"testcase" "{" input grammar "}" /ws -output ::= "output" quoted ";" /ws -input ::= "input" quoted ";" /ws +#import meta.g as grammar + +ws = grammar.ws +ts = ts:: ws! tests ws! +tests = test */ ws +test = tca:: "testcase" "{" input (o::(output +/ ws)) (grammaro::grammar.Grammar) "}" /ws + | tcb:: "testcase" "{" input (grammaro::grammar.Grammar) "}" /ws +output = "output" grammar.Quoted ";" /ws +input = "input" grammar.Quoted ";" /ws