public void Exercise_5_Test()
        {
            // TODO: Add your test code here
            var internetPage = new InternetPage(this.DriverContext);

            internetPage.OpenHomePage();
            internetPage.GoToPage("login");
            var formFormAuthentication = new FormAuthenticationPage(this.DriverContext);

            formFormAuthentication.EnterUserName(BaseConfiguration.Username);
            formFormAuthentication.EnterPassword(BaseConfiguration.Password);
            formFormAuthentication.LogIn();
            Assert.AreEqual("You logged into a secure area!", formFormAuthentication.GetMessageSecure());
        }
Beispiel #2
0
        public void FormAuthenticationPageTestCSV(IDictionary <string, string> parameters)
        {
            var basicAuthPage = new InternetPage(this.DriverContext);

            basicAuthPage.OpenHomePage();
            basicAuthPage.GoToPage("login");
            var formFormAuthentication = new FormAuthenticationPage(this.DriverContext);

            formFormAuthentication.EnterUserName(parameters["user"]);
            formFormAuthentication.EnterPassword(parameters["password"]);
            formFormAuthentication.LogIn();
            Verify.That(
                this.DriverContext,
                () => Assert.AreEqual(parameters["message"], formFormAuthentication.GetMessageSecure()));
        }