Class gUnitExecutor

    • Field Detail

      • numOfTest

        public int numOfTest
      • numOfSuccess

        public int numOfSuccess
      • numOfFailure

        public int numOfFailure
      • numOfInvalidInput

        public int numOfInvalidInput
    • Constructor Detail

      • gUnitExecutor

        public gUnitExecutor​(GrammarInfo grammarInfo,
                             java.lang.String testsuiteDir)
      • gUnitExecutor

        public gUnitExecutor​(GrammarInfo grammarInfo,
                             java.lang.ClassLoader grammarClassLoader,
                             java.lang.String testsuiteDir)
    • Method Detail

      • getGrammarClassLoader

        protected java.lang.ClassLoader getGrammarClassLoader()
      • classForName

        protected final java.lang.Class<?> classForName​(java.lang.String name)
                                                 throws java.lang.ClassNotFoundException
        Throws:
        java.lang.ClassNotFoundException
      • execTest

        public java.lang.String execTest()
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • runLexer

        protected gUnitTestResult runLexer​(java.lang.String lexerName,
                                           java.lang.String testRuleName,
                                           gUnitTestInput testInput)
                                    throws java.lang.Exception
        Throws:
        java.lang.Exception
      • runParser

        protected gUnitTestResult runParser​(java.lang.String parserName,
                                            java.lang.String lexerName,
                                            java.lang.String testRuleName,
                                            gUnitTestInput testInput)
                                     throws java.lang.Exception
        Throws:
        java.lang.Exception
      • runTreeParser

        protected gUnitTestResult runTreeParser​(java.lang.String parserName,
                                                java.lang.String lexerName,
                                                java.lang.String testRuleName,
                                                java.lang.String testTreeRuleName,
                                                gUnitTestInput testInput)
                                         throws java.lang.Exception
        Throws:
        java.lang.Exception
      • checkForValidInput

        protected void checkForValidInput​(CommonTokenStream tokens,
                                          java.io.PrintStream ps2)
        Verify the input has been properly consumed
      • handleUnexpectedException

        protected void handleUnexpectedException​(java.lang.Exception e)