コード例 #1
0
        public void Can_FloodFill_Pupil_Parental_Salutation()
        {
            lock (_lockObject)
            {
                try
                {
                    //Arrange
                    DataPackage dataPackage = GetDataPackage("BU_PUP_PSA_T3", 3);
                    using (new DataSetup(purgeBeforeInsert: false, purgeAfterTest: false, packages: dataPackage))
                    {
                        Select_Year_And_NavigateToBulkUpdateDetailScreen();
                        verifyBeforeActSalutationCells();

                        //Act
                        ParentalSalutationAndAddresseeDetail.DeletePupilParentalSalutationColumnValues();
                        ParentalSalutationAndAddresseeDetail.ExecuteJavaScriptToBulkSelectParentalSalutation();
                        ParentalSalutationAndAddresseeDetail.FloodFillSalutationColumnWithOverride();

                        //Assert
                        verifyAfterActSalutationCells();
                    }
                }
                finally
                {
                    //
                }
            }
        }
コード例 #2
0
        public void Can_Modify_Individual_Pupil_Parental_Salutation()
        {
            lock (_lockObject)
            {
                try
                {
                    //Arrange
                    DataPackage dataPackage = GetDataPackage("BU_PUP_PSA_T4", 6);
                    using (new DataSetup(purgeBeforeInsert: false, purgeAfterTest: false, packages: dataPackage))
                    {
                        Select_Year_And_NavigateToBulkUpdateDetailScreen();
                        verifyBeforeActSalutationCells();

                        //Act
                        ParentalSalutationAndAddresseeDetail.DeletePupilParentalSalutationColumnValues();
                        ParentalSalutationAndAddresseeDetail.ClickFirstCellofColumn(DefaultSalutationColumn);
                        Wait.WaitForAjaxReady(By.ClassName("locking-mask-loading"));
                        ParentalSalutationAndAddresseeDetail.ExecuteJavaScriptToBulkParentalSalutationFloodFillMenuClick();
                        Wait.WaitForAjaxReady(By.ClassName("locking-mask-loading"));
                        ParentalSalutationAndAddresseeDetail.FloodFillSalutationColumnWithOverride();

                        //Assert
                        var cells = (ParentalSalutationAndAddresseeDetail.GetCellText(DefaultSalutationColumn));
                        Assert.IsTrue(cells[0] == FirstSalutationName);
                        IWebElement IsDirtyIndicator = SeleniumHelper.Get(ParentalSalutationAndAddresseeDetail.IsDirtyIndicator);
                        Assert.IsTrue(IsDirtyIndicator.Displayed);
                    }
                }
                finally
                {
                    //
                }
            }
        }
        private void CommonFloodFillTest()
        {
            lock (_commonObject)
            {
                // Initialise
                string firstSalutationName;
                string lastSalutationName;
                string firstAddresseeName;
                string lastAddresseeName;

                //Arrange
                var dataPackage = GetDataPackage("BU_APP_PSA_T1", out firstSalutationName, out lastSalutationName,
                                                 out firstAddresseeName, out lastAddresseeName);

                using (new DataSetup(purgeBeforeInsert: false, purgeAfterTest: false, packages: dataPackage))
                {
                    NavigateToBulkUpdateApplicantParentalSalutationDetailScreen();

                    //Act
                    ParentalSalutationAndAddresseeDetail.DeleteParentalSalutationColumnValues();
                    ParentalSalutationAndAddresseeDetail.ExecuteJavaScriptToBulkSelectParentalSalutation();
                    ParentalSalutationAndAddresseeDetail.FloodFillSalutationColumnWithOverride();

                    //Assert
                    var cells = ParentalSalutationAndAddresseeDetail.GetCellText(DefaultSalutationColumn);

                    Assert.AreEqual(cells[0], firstSalutationName);
                    Assert.AreEqual(cells[1], lastSalutationName);

                    IWebElement IsDirtyIndicator = SeleniumHelper.Get(ParentalSalutationAndAddresseeDetail.IsDirtyIndicator);

                    Assert.IsTrue(IsDirtyIndicator.Displayed, "Page Dirty Indicator");
                }
            }
        }