public void ParseConfigTest() { var target = new DataCollectProcessViewChecklistFieldConfigurator(); var config = string.Empty; DataCollectProcessViewChecklistFieldConfigurator.Config expected = null; var actual = target.ParseConfig(config); Assert.AreEqual(expected, actual); }
public void CreateConfigTest() { var target = new DataCollectProcessViewChecklistFieldConfigurator(); DataCollectProcessViewChecklistFieldConfigurator.Config config = null; var expected = string.Empty; var actual = target.CreateConfig(config); Assert.AreNotEqual(expected, actual); }
public void DataCollectProcessViewChecklistFieldConfiguratorConstructorTest() { var target = new DataCollectProcessViewChecklistFieldConfigurator(); Assert.AreNotEqual(target, null); TestsHelper.TestPublicPropertiesGetSet(target); }
/// <summary> /// Initializes the specified process view field. /// </summary> /// <param name="processViewField">The process view field.</param> /// <param name="templateField">The template field.</param> /// <exception cref="System.ArgumentOutOfRangeException">@Configurator cannot be null.</exception> public void Init(ProcessViewFieldEdit processViewField, IProcessViewFieldTemplate templateField) { _processViewField = processViewField; _configurator = templateField.CustomConfigurator as DataCollectProcessViewChecklistFieldConfigurator; if (_configurator == null) { throw new ArgumentOutOfRangeException(@"Configurator cannot be null."); } LoadFilters(processViewField); var weakListener = new WeakEventListener<DataCollectionChecklistFieldCustomConfigViewModel, ProcessViewFieldEdit, PropertyChangedEventArgs>(this, _processViewField); _processViewField.PropertyChanged += weakListener.OnEvent; weakListener.OnEventAction += OnFieldPropertyChanged; weakListener.OnDetachAction += Static; }