public void CheckSuccessfulChangePassword()
        {
            var accountSettingsInPage = new AccountSettingsInPage(_webDriver);
            var singInPage            = new SingInPage(_webDriver);

            accountSettingsInPage.GoToSingInPage();
            accountSettingsInPage.ClickEditPassword();
            Thread.Sleep(1000);
            accountSettingsInPage
            .SetPassword("QwE147AsD@--")
            .SetNewPassword("QwE147AsD@-")
            .SetReTypeNewPassword("QwE147AsD@-");
            accountSettingsInPage.ClickSaveChanges();
            Thread.Sleep(1000);
            accountSettingsInPage.ClickLogout();
            singInPage.GoToSingInPage()
            .SetEmail("*****@*****.**")
            .SetPassword("QwE147AsD@-")
            .ClickSingUp();
            Thread.Sleep(3000);

            var actualMessage = _webDriver.Url;

            Assert.AreEqual("https://newbookmodels.com/join/company?goBackUrl=%2Fexplore", actualMessage);
        }
Ejemplo n.º 2
0
        public void CheckSuccessfulLogOut()
        {
            var accountSettingsInPage = new AccountSettingsInPage(_webDriver);

            accountSettingsInPage.GoToSingInPage();
            accountSettingsInPage.ClickLogout();
            Thread.Sleep(1000);

            var actualResult = _webDriver.Url;

            Assert.AreEqual("https://newbookmodels.com/auth/signin", actualResult);
        }
        public void CheckSuccessfulAddCard()
        {
            var accountSettingsInPage = new AccountSettingsInPage(_webDriver);

            accountSettingsInPage.GoToSingInPage();
            Thread.Sleep(1000);
            accountSettingsInPage
            .SetCardNumber("4627100101654724")
            .SetMmYy("1225")
            .SetCvc("123")
            .SetFullName("TEST");
            accountSettingsInPage.ClickSaveCard();

            var actualResult = accountSettingsInPage.GetCardNumber();

            Assert.AreEqual("4627100101654724", actualResult);
        }
        public void CheckUpdateCardErrorMessage()
        {
            var accountSettingsInPage = new AccountSettingsInPage(_webDriver);

            accountSettingsInPage.GoToSingInPage();
            Thread.Sleep(1000);
            accountSettingsInPage
            .SetCardNumber("4544444444444444")
            .SetMmYy("1225")
            .SetCvc("123")
            .SetFullName("TEST");
            accountSettingsInPage.ClickSaveCard();
            Thread.Sleep(500);

            var actualMessage = accountSettingsInPage.GetUpdateErrorMessage();

            Assert.AreEqual("Update card info unexpected error", actualMessage);
        }
        public void CheckSuccessfulChangeGeneralInformation()
        {
            var accountSettingsInPage = new AccountSettingsInPage(_webDriver);

            accountSettingsInPage.GoToSingInPage();
            accountSettingsInPage.ClickEditSwitcher();
            Thread.Sleep(1000);
            accountSettingsInPage
            .SetFirstName("Vitalik")
            .SetLastName("Pupkin")
            .SetIndustry("Bentley")
            .SetCompanyLocation("2459 Bentley Ave. Los Angeles CA 90025");
            Thread.Sleep(1000);
            accountSettingsInPage.ClickCompanyLocation();
            accountSettingsInPage.ClickSaveChanges();
            Thread.Sleep(2000);

            var actualResult = accountSettingsInPage.GetCompanyLocation();

            Assert.AreEqual("2459 Bentley Ave. Los Angeles CA 90025", actualResult);
        }