Groovy 2.2.0

org.codehaus.groovy.testng
[Java] Class TestNgRunner

java.lang.Object
  org.codehaus.groovy.testng.TestNgRunner
All Implemented Interfaces:
GroovyRunner

public class TestNgRunner

Integration code for running TestNG tests in Groovy.

Authors:
Paul King


Method Summary
boolean canRun(Class scriptClass, GroovyClassLoader loader)

Utility method to check via reflection if the parsed class appears to be a TestNG test, i.e.

Object run(Class scriptClass, GroovyClassLoader loader)

Utility method to run a TestNG test.

 
Methods inherited from class Object
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll
 

Method Detail

canRun

@SuppressWarnings("unchecked")
public boolean canRun(Class scriptClass, GroovyClassLoader loader)
Utility method to check via reflection if the parsed class appears to be a TestNG test, i.e.&nsbp;checks whether it appears to be using the relevant TestNG annotations.
Parameters:
scriptClass - the class we want to check
loader - the GroovyClassLoader to use to find classes
Returns:
true if the class appears to be a test


run

public Object run(Class scriptClass, GroovyClassLoader loader)
Utility method to run a TestNG test.
Parameters:
scriptClass - the class we want to run as a test
loader - the class loader to use
Returns:
the result of running the test


 

Copyright © 2003-2013 The Codehaus. All rights reserved.