Пример #1
0
        // Be sure that selenium-server-standalone-3.141.59.jar is running
        public SeleniumTests(SeleniumServerFactory <Startup> server)
        {
            this.server = server;
            server.CreateClient();
            var opts = new ChromeOptions();

            opts.AddArgument("--headless"); // Optional, comment this out if you want to SEE the browser window
            opts.AddArgument("no-sandbox");
            this.browser = new RemoteWebDriver(opts);
        }
        public SeleniumTests(SeleniumServerFactory <Startup> server)
        {
            this.server = server;
            server.CreateClient();
            var opts = new ChromeOptions();

            opts.AddArguments("--headless");
            opts.AcceptInsecureCertificates = true;
            this.browser = new ChromeDriver(opts);
        }