1package org.testng.annotations;
2
3/**
4 * This interface captures methods common to @Test and @Configuration
5 *
6 * Created on Dec 20, 2005
7 * @author <a href="mailto:cedric@beust.com">Cedric Beust</a>
8 */
9public interface ITestOrConfiguration extends IParameterizable {
10  /**
11   * Returns the maximum number of milliseconds this test should take.
12   * If it hasn't returned after this time, it will be marked as a FAIL.
13   * @return the maximum number of milliseconds this test should take.
14   */
15  public long getTimeOut();
16  public void setTimeOut(long l);
17
18  /**
19   * The list of groups this class/method belongs to.
20   */
21  public String[] getGroups();
22  public void setGroups(String[] groups);
23
24  /**
25   * The list of groups this method depends on.  Every method
26   * member of one of these groups is guaranteed to have been
27   * invoked before this method.  Furthermore, if any of these
28   * methods was not a SUCCESS, this test method will not be
29   * run and will be flagged as a SKIP.
30   */
31  public String[] getDependsOnGroups();
32  public void setDependsOnGroups(String[] groups);
33
34  /**
35   * The list of methods this method depends on.  There is no guarantee
36   * on the order on which the methods depended upon will be run, but you
37   * are guaranteed that all these methods will be run before the test method
38   * that contains this annotation is run.  Furthermore, if any of these
39   * methods was not a SUCCESS, this test method will not be
40   * run and will be flagged as a SKIP.
41   *
42   *  If some of these methods have been overloaded, all the overloaded
43   *  versions will be run.
44   */
45  public String[] getDependsOnMethods();
46  public void setDependsOnMethods(String[] dependsOnMethods);
47
48  /**
49   * The description for this method, which will be shown in the reports.
50   */
51  public String getDescription();
52  public void setDescription(String description);
53
54}
55