Exemplo n.º 1
0
        public void IfPasswordIsNull_ShowErrorMessage()
        {
            using (var driver = new ChromeDriver())
            {
                LoginPage loginPage = new LoginPage(driver);

                loginPage.Navigate().EmailInput().SendKeys("*****@*****.**");
  
                var displayed = loginPage
                   .Navigate()
                   .Submit()
                   .PasswordErrorMessage()
                   .Displayed;

                Assert.True(displayed);
            }
        }
Exemplo n.º 2
0
        public void IfEmailAddressIsNotValid_ShowValidationMessage()
        {
            using (var driver = new ChromeDriver())
            {
                var loginPage = new LoginPage(driver);
                loginPage.Navigate();

                var emailImput = loginPage.EmailInput();
                emailImput.SendKeys("xxx");

                loginPage
                    .Submit();

                var loginErrorMessage = loginPage.EmailErrorMessage();

                Assert.True(loginErrorMessage.Displayed);
            }
        }