public void MaterialsWeightEntitiesTest_CheckConnection_Success() { var materialsWeightEntities = new MaterialsWeightEntities(); Assert.IsNotNull(materialsWeightEntities.Database.Connection, "There should be connection to the database"); Assert.IsNotNull(materialsWeightEntities.Categories, "There should be categories in the database"); Assert.IsNotNull(materialsWeightEntities.Subcategories, "There should be subcategories in the database"); Assert.IsNotNull(materialsWeightEntities.Materials, "There should be materials in the database"); }
public MaterialList() { Materials = new List <Material>(); MaterialsWeightEntities materialsWeightEntities = new MaterialsWeightEntities(); foreach (var material in materialsWeightEntities.Materials) { Materials.Add(material); } }
public CategoryList() { Categories = new List <Category>(); MaterialsWeightEntities materialsWeightEntities = new MaterialsWeightEntities(); foreach (var category in materialsWeightEntities.Categories) { Categories.Add(category); } }
public SubcategoryList() { Subcategories = new List <Subcategory>(); MaterialsWeightEntities materialsWeightEntities = new MaterialsWeightEntities(); foreach (var subcategory in materialsWeightEntities.Subcategories) { Subcategories.Add(subcategory); } }