Example #1
0
        public void UI_EditQuote_Submitted_Quotes_Cannot_Be_Edited()
        {
            //Given
            //Prepare test data
            EditQuoteSubmittedQuotesCannotBeEditedTestData testData = new EditQuoteSubmittedQuotesCannotBeEditedTestData();

            //1. Navigate to Home page.
            LoginPage loginPage = OpenBreezeApplication();

            //2. Login to Welcome Page
            WelcomePage welcomePage = loginPage.Login();

            //3. Create Quote - Single Vehicle/Single Driver No Additional Coverages
            SummaryPage summaryPage = welcomePage.CreateQuote(testData.Quote);
            string      quoteId     = summaryPage.GetQuoteId();

            //4. Submit Quote
            IndicationPage indicationPage = summaryPage.SelectSubmitButton();

            // Verification
            indicationPage.ValidateIndicationPageDisplayed()
            .ValidateCongratulationsMessageDisplayed();

            //5. Select Close
            indicationPage.SelectCloseButton();
            // Verification
            welcomePage.ValidateWelcomePageDisplayed();

            //6. Open the quote that was just submitted.
            welcomePage.ResumeQuote <SummaryPage>(EnvironmentSetting.WebUrl, quoteId);
            // Verification
            summaryPage.ValidateSummaryPageDisplayed()
            .ValidateSubmittedButtonDisplayed()
            .ValidatePrintIndicationButtonEnabled();

            //7. Select Menu Headers
            foreach (var item in testData.MenuHeaderTitles)
            {
                summaryPage.SelectMenuTitle <SummaryPage>(item);
                // Verification
                summaryPage.ValidateMenuHeaderLinkNotDisplayed(item);
            }

            //8. Select Close
            summaryPage.SelectCloseButton();
            // Verification
            welcomePage.ValidateWelcomePageDisplayed();
        }