public static AssertBindedProperty ( ClassInfo classInfo, string propXmlName, string xmlPropType, bool isList, string propertyName, string propertyType ) : void | ||
classInfo | ClassInfo | |
propXmlName | string | |
xmlPropType | string | |
isList | bool | |
propertyName | string | |
propertyType | string | |
return | void |
public void ShouldHaveVehicles() { ClassInfo vehicle = _classes.Single(c => c.XmlName == "vehicles"); Assert.That(vehicle.Elements.Count, Is.EqualTo(1)); GeneratorAssertHelper.AssertBindedProperty(vehicle, "car", "car", true, "Cars", "IList<Car>"); }
public void ShouldHaveCar() { ClassInfo car = _classes.Single(c => c.XmlName == "car"); Assert.That(car.Elements.Count, Is.EqualTo(3)); GeneratorAssertHelper.AssertStringProperty(car, "brand", false, "Brand"); GeneratorAssertHelper.AssertBindedProperty(car, "color", "color", false, "Color", "Color"); GeneratorAssertHelper.AssertBindedProperty(car, "manufacturer", "manufacturerName", false, "Manufacturer", "ManufacturerName"); }
public void ShouldGenerateFileTest() { ClassInfo file = _classes.Single(c => c.XmlName == "File"); GeneratorAssertHelper.AssertStringProperty(file, "FileName", false, "FileName"); GeneratorAssertHelper.AssertStringProperty(file, "FilePath", false, "FilePath"); GeneratorAssertHelper.AssertStringProperty(file, "URL", false, "URL"); GeneratorAssertHelper.AssertBindedProperty(file, "HashSum", "HashSum", false, "HashSum", "HashSum"); }
public void ShouldHaveColor() { ClassInfo color = _classes.Single(c => c.XmlName == "color"); Assert.That(color.Elements.Count, Is.EqualTo(3)); GeneratorAssertHelper.AssertStringProperty(color, "hue", false, "Hue"); GeneratorAssertHelper.AssertStringProperty(color, "rgb", false, "Rgb"); GeneratorAssertHelper.AssertBindedProperty(color, "description", "colorDescription", false, "Description", "ColorDescription"); }
public void ShouldHaveCar() { ClassInfo car = _classes.Single(c => c.XmlName == "car"); Assert.That(car.Elements.Count, Is.EqualTo(6)); GeneratorAssertHelper.AssertStringProperty(car, "brand", false, "Brand"); GeneratorAssertHelper.AssertBindedProperty(car, "color", "color", false, "Color", "Color"); GeneratorAssertHelper.AssertBindedProperty(car, "manufacturer", "manufacturerName", false, "Manufacturer", "ManufacturerName"); GeneratorAssertHelper.AssertProperty(car, "productionDate", "date", false, "ProductionDate", "DateTime?", false); GeneratorAssertHelper.AssertProperty(car, "exactProductionDate", "dateTime", false, "ExactProductionDate", "DateTime?", false); GeneratorAssertHelper.AssertProperty(car, "modelVersion", "decimal", false, "ModelVersion", "decimal?", false); }
public void ShouldTechnicalImageDetailsHaveMultipleFiles() { ClassInfo techDetails = _classes.Single(c => c.XmlName == "TechnicalImageDetails"); GeneratorAssertHelper.AssertBindedProperty(techDetails, "File", "File", true, "Files", "IList<File>"); }
public void ShouldAdministratingRecordCompanyHasOnePartyId() { ClassInfo catalogItem = _classes.Single(c => c.XmlName == "AdministratingRecordCompany"); GeneratorAssertHelper.AssertBindedProperty(catalogItem, "PartyId", "PartyId", false, "PartyId", "PartyId"); }
public void ShouldCatalogItemHasDisplayTitle() { ClassInfo catalogItem = _classes.Single(c => c.XmlName == "CatalogItem"); GeneratorAssertHelper.AssertBindedProperty(catalogItem, "DisplayTitle", "ReferenceTitle", false, "DisplayTitle", "ReferenceTitle"); }
public void ShouldCatalogItemHasDisplayArtistNameAsString() { ClassInfo catalogItem = _classes.Single(c => c.XmlName == "CatalogItem"); GeneratorAssertHelper.AssertBindedProperty(catalogItem, "DisplayArtistName", "Name", false, "DisplayArtistName", "Name"); }