Ejemplo n.º 1
0
        public static string GetText()
        {
            HomePageElements elements = new HomePageElements();

            elements.alertMessage.Text.ToString();
            return(elements.alertMessage.Text);
        }
Ejemplo n.º 2
0
        public static void FillingLogInForm(string username, string password)
        {
            HomePageElements elements = new HomePageElements();

            elements.email.SendKeys(username);
            elements.password.SendKeys(password);
            Driver.Wait();
        }
Ejemplo n.º 3
0
        public static void InvalidPassword()
        {
            HomePageElements elements = new HomePageElements();

            elements.prijaviSe.Click();
            elements.email.SendKeys(Configuration.Credentials.ValidCredentials.Username);
            elements.password.SendKeys(Configuration.Credentials.InvalidCredentials.Password);
            elements.logInButton.Click();
            Driver.Wait();
        }
Ejemplo n.º 4
0
        public static void LogOut(IWebDriver driver)
        {
            HomePageElements elements = new HomePageElements();

            Actions action = new Actions(driver);

            //action.MoveToElement(driver.FindElement(By.XPath("/html/body/header/div[1]/nav/div[@class='flex items-center']/div[1]/a[@href='/moj-kutak']/span[.='Moj nalog']")))
            // .Build().Perform();

            action.MoveToElement(elements.logOutIcon).MoveToElement(elements.logOut).Click().Build().Perform();
            //elements.logOut.Click();
        }