0

So I use RemoteTesttRunner to run a couple of tests with selenium and they work perfectly the first time I run them. But if I try to run them a second time the web browser don't show up and he fail the test directly.

I run the tests like this:

var location = AppDomain.CurrentDomain.BaseDirectory;
var runner = new RemoteTestRunner();
runner.Load(new TestPackage(Path.Combine(location,"/my_test.dll")));
var result = runner.Run(new NullListener(), TestFilter.Empty, false, LoggingThreshold.All);
return result;

And the test I run look like this:

    [Test]
    public void AutomationTest()
    {
        ChromeDriver driver = new ChromeDriver()
        driver.Navigate().GoToUrl("www.google.se")
    }

So is there something I need to clean after every test or why does the web browser not show up after my first test run? As it run just fine the first time I can't find any wrong with the code.

Should add that I don't get any exception or anything like that, it just don't show up.

MilleB
  • 1,470
  • 2
  • 19
  • 32
  • Do you have multiple tests? and all of them run fine first time? Or, only the test above works other don't? – Saifur Feb 09 '15 at 21:38
  • I have multiple (just for test) and they run fine. I have also tried to run them directly inside visual studio and it works fine. But if I use RemoteTestrunner inside another application they only run once. I guess it have something to do with that it can't open the webbrowser again. – MilleB Feb 10 '15 at 09:02

0 Answers0