Package org.testng.annotations
Annotation Type ObjectFactory
-
@Retention(RUNTIME) @Target(METHOD) public @interface ObjectFactoryMarks a method as the object factory to use for creating all test instances. The test classes can only contain one method marked with this annotation, and the method must return an instance ofITestObjectFactory.