Quantcast
Channel: Active questions tagged selenium - Stack Overflow
Viewing all articles
Browse latest Browse all 98814

Chrome is not opening the url by using GoToUrl Method

$
0
0
using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using OpenQA.Selenium;
using OpenQA.Selenium.Chrome;

namespace SeleniumAuto_test_
{
    [TestClass]
    public class UnitTest1
    {
        [TestMethod]
        public void TestMethod1()
        {
            IWebDriver d = new ChromeDriver();
            d.Navigate().GoToUrl("http://www.google.com");
            IWebElement e = d.FindElement(By.Name("q"));
            e.SendKeys("automation");

        }
    }
}

I have added the package of Selenium Web driver & WebDriverChromeDriver for this project online through NuGet packages. I have testing it out but its only opening the Chrome and nothing else is working! The test case is failing again and again. I have tried adding reference by downloading them from Selenium-HQ web page too. Help will be appreciated.:)


Viewing all articles
Browse latest Browse all 98814

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>