예제 #1
0
        public void DeleteCustomerSuccess1(CustomerManagementData input)
        {
            CustomerManageSetting.FocusOnCustomer(input.InputData.CommonName);
            TimeManager.LongPause();

            CustomerManageSetting.ClickDeleteButton();
            TimeManager.LongPause();

            CustomerManageSetting.ClickMsgBoxDeleteButton();
            TimeManager.LongPause();
            TimeManager.LongPause();


            Assert.IsFalse(CustomerManageSetting.IsCustomerOnList(input.InputData.CommonName));

            UserSettings.NavigatorToUserSetting();
            TimeManager.LongPause();
            TimeManager.LongPause();
            TimeManager.LongPause();
            TimeManager.LongPause();

            UserSettings.FocusOnUser("UserA");
            TimeManager.LongPause();
            Assert.IsTrue(UserSettings.IsUserOnList("UserA"));
            Assert.IsTrue(UserSettings.IsUserOnList("UserB"));
            Assert.IsTrue(UserSettings.IsUserOnList("UserC"));

            CustomerManageSetting.NavigateToCustomerSetting();
            TimeManager.LongPause();
            TimeManager.LongPause();

            //Re-select a deleted customer to display error message

            HomePagePanel.SelectCustomer(input.InputData.CommonName);
            Assert.AreEqual(JazzMessageBox.MessageBox.GetMessage(), input.ExpectedData.Message);
            CustomerManageSetting.ClickMsgBoxCloseButton();
            TimeManager.LongPause();
            JazzFunction.LoginPage.LoginWithOption("SchneiderElectricChina", "P@ssw0rdChina", "[email protected]");
            TimeManager.LongPause();

            //Assert.IsFalse(HomePagePanel.IsCustomerExistedInCustomerSelectionDialog(input.InputData.CommonName));
        }