public TestActionExecutor(SeleniumContext seleniumContext) { _beforeTestActions = new List <IBeforeTestAction>(); _afterTestActions = new List <IAfterTestAction> { new CloseDriverAction(seleniumContext.WebDriver) }; }
public GameTwist_End_To_End_Steps(Settings settings, SeleniumContext _seleniumContext, CommonRequest _commonRequest, SeleniumCommonPg _seleniumCommonPg) { _settings = settings; seleniumContext = _seleniumContext; commonRequest = _commonRequest; seleniumCommonPg = _seleniumCommonPg; }
public BasePage(string url, SeleniumContext seleniumContext, ConfigReader configReader) { this.url = url; Driver = seleniumContext.WebDriver; WaitForElementExists = configReader.Config.Timeouts.WaitForElementExists; WaitForElementToBeInteractable = configReader.Config.Timeouts.WaitForElementToBeInteractable; }
public HomePageService(HomePageObject pageObject, SeleniumContext seleniumContext, TestConfiguration testConfiguration) { _pageObject = pageObject; _webDriver = seleniumContext.WebDriver; _testConfiguration = testConfiguration; }
public PublicBrowseSteps(SeleniumContext context, Settings settings) { _context = context; _publicBrowseBaseUrl = settings.PublicBrowseBaseUrl; _publicBrowseLoginUrl = settings.PublicBrowseLoginUrl; _publicBrowseLogoutUrl = settings.PublicBrowseLogoutUrl; }
public EmailSteps(EmailServerDriver emailServerDriver, Settings settings, SeleniumContext seleniumContext, ScenarioContext context) { this.emailServerDriver = emailServerDriver ?? throw new ArgumentNullException(nameof(emailServerDriver)); this.settings = settings ?? throw new ArgumentNullException(nameof(settings)); this.seleniumContext = seleniumContext; this.context = context; }
public LoginSteps(SeleniumContext context, Settings settings) { this.context = context; sampleMvcBaseUrl = settings.SampleMvcClientBaseUrl; identityApiBaseUrl = settings.IdentityApiBaseUrl; }
public DomElement(IWebElement element, RemoteWebDriver driver, SeleniumContext context, string searchedSelector = null) { _element = element; _driver = driver; _context = context; _searchedSelector = searchedSelector; }
public RegistrationSteps( IConfiguration configuration, ScenarioContext context, SeleniumContext seleniumContext) { _context = context; _discovery = configuration.GetValue <string>("DiscoveryAddress"); _seleniumContext = seleniumContext; }
public RegistrationSteps( IConfiguration configuration, ScenarioContext context, SeleniumContext seleniumContext) { this.context = context; discovery = configuration.GetValue <Uri>("DiscoveryAddress"); this.seleniumContext = seleniumContext; }
private IWebElement WaitUntilElementClickable(SeleniumContext seleniumContext, By elementLocator, int timeout = 10) { try { var wait = new WebDriverWait(seleniumContext.WebDriver, TimeSpan.FromSeconds(timeout)); return(wait.Until(ExpectedConditions.ElementToBeClickable(elementLocator))); } catch (NoSuchElementException) { Console.WriteLine("Element with locator: '" + elementLocator + "' was not found in current context page."); throw; } }
// GET: Selenium public ActionResult Selenium() { ViewBag.Messege = "Yahoo Finance"; var url = "https://login.yahoo.com/"; IWebDriver chromeDriver = new ChromeDriver(); chromeDriver.Navigate().GoToUrl(url); var wait = new WebDriverWait(chromeDriver, TimeSpan.FromSeconds(15)); wait.Until(cdrver => cdrver.FindElement(By.XPath("//input[@id='login-username']"))); chromeDriver.FindElement(By.Id("login-username")).SendKeys("Ilovecheese5"); chromeDriver.FindElement(By.Id("login-username")).Submit(); using (var db = new SeleniumContext()) { return(View(db)); } }
public UiInteractionSteps(SeleniumContext seleniumContext) { this.seleniumContext = seleniumContext; }
public void RunBeforeScenario() { SeleniumContext = new SeleniumContext(); _objectContainer?.RegisterInstanceAs(SeleniumContext); }
public LoginPage(SeleniumContext seleniumContext, ConfigReader configReader) : base("https://onlineservices.ubs.com/", seleniumContext, configReader) { }
public Workspace(SeleniumContext context) { _context = context; _context.Driver.Navigate().GoToUrl(Settings.Default.DefaultUrl + "/#/Workspace"); }
public UiStepsLogin(SeleniumContext seleniumContext) { ////save the context so you can use it in your tests this.seleniumContext = seleniumContext; }
public Navigator(RemoteWebDriver driver, SeleniumContext seleniumContext) { _driver = driver; _seleniumContext = seleniumContext; }
public MainPage(SeleniumContext seleniumContext, ConfigReader configReader) : base("https://www.ubs.com/", seleniumContext, configReader) { }
public RealizarUmaCompraSteps(SeleniumContext seleniumContext) { this.seleniumContext = seleniumContext; wait = new WebDriverWait(seleniumContext.WebDriver, TimeSpan.FromSeconds(10)); realizarUmaCompraPageObject = new RealizarUmaCompraPageObject(seleniumContext.WebDriver); }
public WorkItemTree(SeleniumContext context) { _context = context; }
public LogoutSteps(SeleniumContext context, Settings settings) { _context = context; _identityApiBaseUrl = settings.IdentityApiBaseUrl; }
public HomePageObject(SeleniumContext seleniumContext) { PageFactory.InitElements(seleniumContext.WebDriver, this); }
public SeleniumCommonPg(SeleniumContext _seleniumContext) { seleniumContext = _seleniumContext; }
public CleanUpSteps(SeleniumContext seleniumContext) { this.SeleniumContext = seleniumContext; }
public GoogleSearchSteps(SeleniumContext seleniumContext) { this.seleniumContext = seleniumContext; }
public UiValidationSteps(SeleniumContext seleniumContext) { _seleniumContext = seleniumContext; }
public Screenshots(SeleniumContext seleniumContext) { ////save the context so you can use it in your tests this.seleniumContext = seleniumContext; }
public ErrorSteps(SeleniumContext seleniumContext) { this.seleniumContext = seleniumContext; }
public static void BeforeTestRun() { seleniumContext = new SeleniumContext(); }
public DomWrapper(RemoteWebDriver driver, SeleniumContext context) { _driver = driver; _context = context; }
public StackCloneSteps(SeleniumContext seleniumContext) { this.seleniumContext = seleniumContext; }