Example #1
0
        public void Excercise2(string url, string loginName, string password, string firstName, string lastName, string email, string country)
        {
            driver.Navigate().GoToUrl(url);
            var       adminLoginPage = new AdminLoginPage(driver);
            AdminPage adminPage      = adminLoginPage.LogIn(loginName, password);

            adminPage.ClickAdmins();
            AddAdminsPage addAdminsPage = adminPage.ClickAdd();

            adminPage = addAdminsPage.AddNewAdmin(firstName, lastName, email, password, country);
            try
            {
                Assert.IsTrue(adminPage.IsRowExist(firstName, lastName, email), "Admin is not created");
            }
            finally
            {
                adminPage.ClickDeleteAdmin(email);
            }
        }