1 8 9 package net.sourceforge.chaperon.test; 10 11 import junit.framework.Test; 12 import junit.framework.TestCase; 13 import junit.framework.TestSuite; 14 15 import net.sourceforge.chaperon.common.SimpleParser; 16 17 import java.io.File ; 18 19 public class SimpleParserTestCase extends TestCase 20 { 21 public SimpleParserTestCase(String name) 22 { 23 super(name); 24 } 25 26 public void testSimpleParser() throws Exception 27 { 28 File lexicon = new File ("src/resources/grammars/grm.xlex"); 29 File grammar = new File ("src/resources/grammars/grm.xgrm"); 30 File in = new File ("src/resources/grammars/java.grm"); 31 File out = new File ("build/chaperon/simpleparser.test"); 32 33 SimpleParser.process(lexicon, grammar, in, out); 35 } 36 37 public static Test suite() 38 { 39 return new TestSuite(SimpleParserTestCase.class); 40 } 41 } 42 | Popular Tags |