X-Git-Url: http://git.megacz.com/?p=sbp.git;a=blobdiff_plain;f=tests%2Ftestcase.g;h=0308ad68ce06a9c12881dd2faed3dc0fb0035223;hp=cc6fd20ee041ab0e50c059a560df5c0ca5f651e0;hb=1d5f76f8144b739719737bfe75f321caf67cfa19;hpb=bad286576656a73e315f0aa7b08a1c1714eb8390 diff --git a/tests/testcase.g b/tests/testcase.g index cc6fd20..0308ad6 100644 --- a/tests/testcase.g +++ b/tests/testcase.g @@ -1,6 +1,12 @@ -ts = ts:: !ws tests !ws -tests = test */ ws -test = tca:: "testcase" "{" input (o::(output +/ ws)) (grammaro::Grammar) "}" /ws - | tcb:: "testcase" "{" input (grammaro::Grammar) "}" /ws -output = "output" Quoted ";" /ws -input = "input" Quoted ";" /ws +#import meta.g as grammar +// this is a testx +s = ws! (TestCases:: TestCase */ ws) ws! +Input = "input" grammar.Quoted ";" /ws +Output = "output" grammar.Quoted ";" /ws +Outputs:: = Output */ ws +TestCase:: = "testcase" grammar.Quoted "{" + Input + Outputs + (SubGrammar:: grammar.Grammar) + "}" /ws +ws = grammar.ws