public void Can_Save_BulkUpdate_Applicant_Parental_Salutation_Save() { lock (_commonObject) { string firstSalutationName; string lastSalutationName; string firstAddresseeName; string lastAddresseeName; //Arrange DataPackage dataPackage = GetDataPackageWithNoSalutation("BU_APP_PSA_T2", out firstSalutationName, out lastSalutationName, out firstAddresseeName, out lastAddresseeName); using (new DataSetup(purgeBeforeInsert: false, purgeAfterTest: false, packages: dataPackage)) { var bulkUpdateNavigation = new AdmissionsBulkUpdateNavigation(); bulkUpdateNavigation.NavgateToPupilBulkUpdate_SubMenu( AdmissionsBulkUpdateElements.BulkUpdate.MenuItems.ApplicantSalutationAddresseeMenuItem, LoginAs); SeleniumHelper.ToggleCheckbox(AdmissionsBulkUpdateElements.BulkUpdate.Search.MissingSalutationCheckboxName); SeleniumHelper.ToggleCheckbox(AdmissionsBulkUpdateElements.BulkUpdate.Search.MissingAddresseeCheckboxName); SeleniumHelper.ChooseSelectorOption(ParentalSalutationAndAddresseeDetail.YearGroupDropDownList, _admissionYear); SeleniumHelper.ChooseSelectorOption(ParentalSalutationAndAddresseeDetail.SchoolIntakeDropDownList, _schoolIntakeName); SeleniumHelper.ChooseSelectorOption(ParentalSalutationAndAddresseeDetail.AdmissionGroupDropDownList, _admissionGroupName); //SeleniumHelper.FindAndClick(PupilBulkUpdateElements.BulkUpdate.Search.SearchButton, TimeSpan.FromSeconds(20)); SeleniumHelper.WaitForElementClickableThenClick(AdmissionsBulkUpdateElements.BulkUpdate.Search.SearchButton); var rowCount = SeleniumHelper.Get(AdmissionsBulkUpdateElements.BulkUpdate.Detail.RowCount); Assert.AreEqual("Rows: 2", rowCount.Text); ParentalSalutationAndAddresseeDetail.ClickFirstCellofColumn(DefaultSalutationColumn); ParentalSalutationAndAddresseeDetail.GetEditor().SendKeys("test"); SeleniumHelper.WaitForElementClickableThenClick( AdmissionsBulkUpdateElements.BulkUpdate.MenuItems.PupilBulkUpdateSaveButton); WebDriverWait waiter = new WebDriverWait(WebContext.WebDriver, TimeSpan.FromSeconds(AdmissionsBulkUpdateElements.BulkUpdate.Detail.Timeout)); waiter.Until(ExpectedConditions.ElementIsVisible(AdmissionsBulkUpdateElements.BulkUpdate.Detail.SaveMessageCss)); string actualText = WebContext.WebDriver.FindElement(AdmissionsBulkUpdateElements.BulkUpdate.Detail.SaveMessageCss).Text; Assert.AreEqual(AdmissionsBulkUpdateElements.BulkUpdate.Detail.SaveMessage, actualText); } } }