private static CQuantity Map(this C_DV_QUANTITY model) { var quantity = new CQuantity { ReferenceModelTypeName = model.rm_type_name, NodeId = model.node_id }; if (model.property != null) { quantity.Property = model.property.Map(); } if (model.occurrences != null) { quantity.Occurences = model.occurrences.Map(); } foreach (C_QUANTITY_ITEM unit in model.list) { quantity.QuantityConstraints.Add(new CQuantityItem { Units = unit.units, Magnitude = unit.magnitude.Map() }); } return(quantity); }
public void IsValidValueThrowsException() { var instance = new CQuantity(); var result = instance.IsValidValue(null); }
public void DefaultValueThrowsException() { var instance = new CQuantity(); var result = instance.DefaultValue(); }
public void IsSubsetOfThrowsException() { var instance = new CQuantity(); var result = instance.IsSubsetOf(null); }
public void ListsAreNotNull() { var instance = new CQuantity(); Assert.IsNotNull(instance.QuantityConstraints); }