Code example for TestResult

Methods: addErrorendTeststartTest

0
        return 1; 
    } 
 
    public void run(TestResult result) {
        try { 
            result.startTest(this);
 
            // lets run the script 
            InvokerHelper.runScript(scriptClass, arguments);
            result.endTest(this);
        } 
        catch (Exception e) {
            result.addError(this, e);
        } 
    } 
 
    public String toString() {
        return "TestCase for script: " + scriptClass.getName();
    } 
}