I have a test that I'm trying to run parallel in multiple browsers(IE, Chrome and Firefox).
[SetUp]
public void TestInitialize()
{
//EnvironmentAccess.LoadEnvironment();
// Create a new instance of the Firefox driver
//driver = new FirefoxDriver();
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities = DesiredCapabilities.Firefox();
capabilities.SetCapability(CapabilityType.BrowserName, "firefox");
capabilities.SetCapability(CapabilityType.Platform, new Platform(PlatformType.Windows));
driver = new RemoteWebDriver(new Uri("http://localhost:4444/wd/hub"), capabilities);
}
[Test]
public void SampleTest()
{
string url = "https://google.com";
try
{
driver.Navigate().GoToUrl(url);
}
//other test code
}
[TearDown]
public void TearDown()
{
driver.Quit();
driver.Dispose();
}
I can't figure out how to make it run across multiple browsers. I've seen it be done in java but i'm trying to do it through c#. I read about gallio but couldn't understand howto integrate it properly in my code.