01: package org.testng.internal.annotations;
02:
03: import org.testng.IRetryAnalyzer;
04:
05: /**
06: * Encapsulate the @Test / @testng.test annotation.
07: *
08: * Created on Dec 20, 2005
09: * @author <a href = "mailto:cedric@beust.com">Cedric Beust</a>
10: */
11: public interface ITest extends ITestOrConfiguration {
12: /**
13: * Returns the maximum number of milliseconds this test should take.
14: * If it hasn't returned after this time, it will be marked as a FAIL.
15: * @return the maximum number of milliseconds this test should take.
16: */
17: public long getTimeOut();
18:
19: public void setTimeOut(long l);
20:
21: /**
22: * Returns the number of times this method should be invoked.
23: * @return the number of times this method should be invoked.
24: */
25: public int getInvocationCount();
26:
27: public void setInvocationCount(int l);
28:
29: /**
30: * The size of the thread pool for this method. The method will be invoked
31: * from multiple threads as specified by invocationCount.
32: * Note: this attribute is ignored if invocationCount is not specified
33: */
34: public int getThreadPoolSize();
35:
36: public void setThreadPoolSize(int n);
37:
38: /**
39: * The percentage of success expected from this method.
40: */
41: public int getSuccessPercentage();
42:
43: public void setSuccessPercentage(int s);
44:
45: /**
46: * If set to true, this test method will always be run even if it depends
47: * on a method that failed. This attribute will be ignored if this test
48: * doesn't depend on any method or group.
49: */
50: public boolean getAlwaysRun();
51:
52: public void setAlwaysRun(boolean f);
53:
54: public Class<?>[] getExpectedExceptions();
55:
56: public void setExpectedExceptions(Class<?>[] e);
57:
58: public String getSuiteName();
59:
60: public void setSuiteName(String s);
61:
62: public String getTestName();
63:
64: public void setTestName(String s);
65:
66: public boolean getSequential();
67:
68: public void setSequential(boolean f);
69:
70: public String getDataProvider();
71:
72: public Class<?> getDataProviderClass();
73:
74: public IRetryAnalyzer getRetryAnalyzer();
75:
76: public void setRetryAnalyzer(Class<?> c);
77:
78: public boolean skipFailedInvocations();
79:
80: public void setSkipFailedInvocations(boolean skip);
81: }
|