Package org.testng.internal.annotations

Examples of org.testng.internal.annotations.IConfiguration


    return m_inheritGroupsFromTestClass;
  }
 
  private void init() {
    IAnnotation a = AnnotationHelper.findConfiguration(m_annotationFinder, m_method);
    IConfiguration annotation = (IConfiguration) a;
    if (a != null) {
      m_inheritGroupsFromTestClass = annotation.getInheritGroups();
      setDescription(annotation.getDescription());
    }

    if (annotation != null && annotation.isFakeConfiguration()) {
     if (annotation.getBeforeSuite()) initGroups(IBeforeSuite.class)
     if (annotation.getAfterSuite()) initGroups(IAfterSuite.class)
     if (annotation.getBeforeTest()) initGroups(IBeforeTest.class)
     if (annotation.getAfterTest()) initGroups(IAfterTest.class)
     if (annotation.getBeforeGroups().length != 0) initGroups(IBeforeGroups.class)
     if (annotation.getAfterGroups().length != 0) initGroups(IAfterGroups.class);
     if (annotation.getBeforeTestClass()) initGroups(IBeforeClass.class)
     if (annotation.getAfterTestClass()) initGroups(IAfterClass.class)
     if (annotation.getBeforeTestMethod()) initGroups(IBeforeMethod.class)
     if (annotation.getAfterTestMethod()) initGroups(IAfterMethod.class)
    }
    else {
      initGroups(IConfiguration.class);
    }
View Full Code Here


     
      //
      // @Configuration method
      //
      else {
        IConfiguration annotation = AnnotationHelper.findConfiguration(finder, m);
        if (annotation.getAlwaysRun()) {
          in = true;
        }
        else {
          in = includeMethod(AnnotationHelper.findTest(finder, m),
              runInfo, tm, forTests, unique, outIncludedMethods);
View Full Code Here

                                             tm,
                                             null,
                                             System.currentTimeMillis(),
                                             System.currentTimeMillis());

      IConfiguration configurationAnnotation= null;
      try {
        Object[] instances= tm.getInstances();
        if (instances == null || instances.length == 0) instances = new Object[] { instance };
        Class<?> objectClass= instances[0].getClass();
        Method method= tm.getMethod();
View Full Code Here

  public static String[] dependentGroupsForThisMethodForConfiguration(Method m,
                                                                      IAnnotationFinder finder) {
    String[] result = {};

    // Collect groups on the method
    IConfiguration tm = AnnotationHelper.findConfiguration(finder, m);
    if (null != tm) {
      result = tm.getDependsOnGroups();
    }

    return result;
  }
View Full Code Here

TOP

Related Classes of org.testng.internal.annotations.IConfiguration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.