Annotation Interface BrowserConfiguration


@Retention(RUNTIME) @Target(METHOD) public @interface BrowserConfiguration

Methods annotated with BrowserConfiguration in test classes will be used to configure the browsers that are to be used for test cases in that class. Each test case is run on each of the browsers returned by the method.

Methods annotated with BrowserConfiguration annotation should return a Collection<DesiredCapabilities>

Example:

 @BrowserConfiguration
 public List<DesiredCapabilities> firefoxAndChromeConfiguration() {
     List<DesiredCapabilities> list = new ArrayList<DesiredCapabilities>();
     list.add(Browser.FIREFOX.getDesiredCapabilities());
     list.add(Browser.CHROME.getDesiredCapabilities());
     return list;
 }