Class TestSuite


  • public class TestSuite
    extends Object
    • Constructor Detail

      • TestSuite

        public TestSuite​(TestReport report)
    • Method Detail

      • getWriter

        public Writer getWriter()
        The writer to use with this test suite
        Returns:
        the current writer
      • setWriter

        public void setWriter​(Writer writer)
        Sets the writer used by this test suite
        Parameters:
        writer - the writer to use
      • getReport

        public TestReport getReport()
        Returns:
        the current suite Report
      • setReport

        public void setReport​(TestSuiteReport report)
        Sets the current suite report
        Parameters:
        report - the current suite report
      • isRunningSuite

        public boolean isRunningSuite()
        Returns:
        true is a test suite is being run or false otherwise
      • isDebug

        public boolean isDebug()
      • setDebug

        public void setDebug​(boolean debug)
      • onException

        public void onException​(String nodeText,
                                String message,
                                Throwable exception)
        Records an exception in the report
        Parameters:
        nodeText - the current cell on the table
        message - a message to record with the exception
        exception - the exception to record
      • onFailure

        public void onFailure​(String nodeText,
                              String actualValue,
                              String message)
        Records a test failure in the report
        Parameters:
        nodeText - the current cell text on the table
        actualValue - the value that was returned from the execution
        message - a message to record with the failure
      • onPass

        public void onPass​(String nodeText,
                           String message)
        Records a test pass in the report
        Parameters:
        nodeText - the current cell text on the table
        message - a message to record with the pass
      • onDebug

        public void onDebug​(String nodeText,
                            String message)
        Records a debug message in the report
        Parameters:
        nodeText - the current cell text on the table
        message - a message to record with the pass
      • getReportDetail

        public String getReportDetail()
        Determines how much detail is shown in the report
        Returns:
        one of the detail levels, either REPORT_DETAIL_ALL, REPORT_DETAIL_TEST_FIXTURE or REPORT_DETAIL_TEST_SUITE
      • setReportDetail

        public void setReportDetail​(String reportDetail)
        Determines how much detail is shown in the report
        Parameters:
        reportDetail - ne of the detail levels, either REPORT_DETAIL_ALL, REPORT_DETAIL_TEST_FIXTURE or REPORT_DETAIL_TEST_SUITE
      • getCurrentRequest

        public javax.servlet.http.HttpServletRequest getCurrentRequest()
        Returns the current page request
        Returns:
        the current page request
      • setCurrentRequest

        public void setCurrentRequest​(javax.servlet.http.HttpServletRequest currentRequest)
        Sets the current page request
      • getCurrentRequestUrl

        public String getCurrentRequestUrl()
        Retrieves the full URL including parameters for the current request
      • isStopRunning

        public boolean isStopRunning()
      • setStopRunning

        public void setStopRunning​(boolean stopRunning)
      • isStopOnException

        public boolean isStopOnException()
      • setStopOnException

        public void setStopOnException​(boolean stopOnException)