1 package com.atlassian.selenium;
2
3 import junit.framework.TestResult;
4 import junit.framework.TestSuite;
5
6 import java.lang.reflect.InvocationHandler;
7 import java.lang.reflect.Proxy;
8 import java.util.List;
9
10 /**
11 * A skeleton test suite for Selenium tests. The run method starts the selenium server (if the
12 * selenium configuration class has been set to allow this.
13 *
14 * @since v3.12
15 */
16 public abstract class SeleniumMultiTestSuite extends TestSuite
17 {
18
19 /**
20 * To be implemented by users of this class.
21 * @return an implementation of the SeleniumConfiguration interface containing the appropriate
22 * selenium configuration information.
23 */
24 protected abstract List<SeleniumConfiguration> getSeleniumConfigurations();
25
26
27 /**
28 * A special run methods that, depending on the SeleniumConfiguration, will start the selenium
29 * server and client.
30 * @param testResult Test results class to be passed to parent
31 */
32 public final void run(TestResult testResult){
33 SeleniumStarter.getInstance().start(getSeleniumConfigurations());
34 SeleniumStarter.getInstance().setManual(false);
35 super.run(testResult);
36 SeleniumStarter.getInstance().stop();
37 }
38
39
40 }