Skip to content

Instantly share code, notes, and snippets.

@angelovstanton
Last active August 7, 2017 03:09
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save angelovstanton/e5bfec4b8ea8e540c4a2780d4979bf2b to your computer and use it in GitHub Desktop.
Save angelovstanton/e5bfec4b8ea8e540c4a2780d4979bf2b to your computer and use it in GitHub Desktop.
using OpenQA.Selenium;
namespace HuddlePageObjectsElementsStringProperties.ImprovedVersion
{
public partial class BingMainPage
{
private readonly IWebDriver _driver;
private readonly string url = @"http://www.bing.com/";
public BingMainPage(IWebDriver browser)
{
_driver = browser;
}
public void Navigate()
{
_driver.Navigate().GoToUrl(url);
}
public void Search(string textToType)
{
SearchBox.Clear();
SearchBox.SendKeys(textToType);
GoButton.Click();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment