public void ModifyCustomerConsumptionSettingCancelled(CustomerManagementData input) { //Select an existing customer. CustomerManageSetting.FocusOnCustomer(input.InputData.CommonName); //Open 'Consumption Setting For Map' (地图页信息) tab. CustomerManageSetting.NavigateToCustmerMapPageInfoSetting(); TimeManager.MediumPause(); //Click 'Modify' button. CustomerManageSetting.ClickModifyMapPropertyButton(); TimeManager.MediumPause(); //Click Save button directly without any modification. CustomerManageSetting.ClickSaveMapPropertyButton(); TimeManager.ShortPause(); Assert.IsTrue(CustomerManageSetting.AreDefaultOptionsChecked()); //Click 'Modify' button. CustomerManageSetting.ClickModifyMapPropertyButton(); TimeManager.MediumPause(); //Check one option.Uncheck one option. CustomerManageSetting.CheckMapInformation(input.InputData.MapOptions[0]); CustomerManageSetting.UnCheckMapInformation(input.InputData.MapOptions[1]); //But Click Cancel button. CustomerManageSetting.ClickCancelMapPropertyButton(); TimeManager.ShortPause(); //• No 'Cancel' button on the page after cancelled. Assert.IsFalse(CustomerManageSetting.IsCancelMapPropertyButtonDisplayed()); //• The modification is cancelled and information remains as before. Assert.IsTrue(CustomerManageSetting.AreDefaultOptionsChecked()); }
public void ModifyCustomerConsumptionSettingValid(CustomerManagementData input) { //Select an existing customer. CustomerManageSetting.FocusOnCustomer(input.InputData.CommonName); //Open 'Consumption Setting For Map' (地图页信息) tab. CustomerManageSetting.NavigateToCustmerMapPageInfoSetting(); TimeManager.MediumPause(); //Click 'Modify' button. CustomerManageSetting.ClickModifyMapPropertyButton(); TimeManager.MediumPause(); //Display all the Industry3 available selections including Assert.IsTrue(CustomerManageSetting.AreDefaultOptionsChecked()); //CustomerManageSetting.AreItemsChecked(input.InputData.MapOptions); Assert.IsTrue(CustomerManageSetting.AreItemsUnChecked(input.ExpectedData.MapOptions)); //Check one option.Uncheck one option. CustomerManageSetting.CheckMapInformation(input.InputData.MapOptions[0]); TimeManager.ShortPause(); CustomerManageSetting.UnCheckMapInformation(input.InputData.MapOptions[1]); //• Checked options are displayed in View mode. //• Unchecked options are NOT displayed in View mode. CustomerManageSetting.ClickSaveMapPropertyButton(); TimeManager.ShortPause(); Assert.IsTrue(CustomerManageSetting.IsItemChecked(input.InputData.MapOptions[0])); Assert.IsTrue(CustomerManageSetting.IsItemUnChecked(input.InputData.MapOptions[1])); }