public override void TestInitialize() { base.TestInitialize(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { Roles.Instance.Add(Role.Random()); } }
public static MeasureTerms Random() { var t = new MeasureTerms(); for (var i = 0; i < GetRandom.Count(); i++) { t.Add(MeasureTerm.Random()); } return(t); }
public static UnitTerms Random() { var t = new UnitTerms(); for (var i = 0; i < GetRandom.Count(); i++) { t.Add(UnitTerm.Random()); } return(t); }
[TestInitialize] public override void TestInitialize() { base.TestInitialize(); obj = TestClass.Random(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { Attributes.Instance.Add(Attribute.Random()); } }
public static ProductTypes Random() { var r = new ProductTypes(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(ProductType.Random()); } return(r); }
public static Entities Random() { var e = new Entities(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { e.Add(Entity.Random()); } return(e); }
public static RoleTypes Random() { var r = new RoleTypes(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(RoleType.Random()); } return(r); }
public static Products Random(byte min = 3, byte max = 10) { var p = new Products(); var c = GetRandom.Count(min, max); for (var i = 0; i < c; i++) { p.Add(ProductInstance.GetRandomDerived()); } return(p); }
public new static OrderUses Random() { var r = new OrderUses(); var c = GetRandom.Count(1, 2); for (var i = 0; i < c; i++) { r.Add(GetRandom.String(5, 7)); } return(r); }
protected override Archetypes <string> GetRandomObj() { var a = new Archetypes <string>(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { a.Add(GetRandom.String()); } return(a); }
public static RoleConstraints Random() { var r = new RoleConstraints(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(RoleConstraint.Random()); } return(r); }
public static CatalogEntries Random() { var r = new CatalogEntries(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(CatalogEntry.Random()); } return(r); }
public static Contacts Random() { var r = new Contacts(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(ContactInstance.Random()); } return(r); }
public static InventoryEntries Random() { var r = new InventoryEntries(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(InventoryEntry.Random()); } return(r); }
public static Units Random() { var u = new Units(); var c = GetRandom.Count(2, 5); for (int i = 0; i < c; i++) { u.Add(Unit.Random()); } return(u); }
public static Relationships Random() { var r = new Relationships(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(Relationship.Random()); } return(r); }
public static Orders Random() { var r = new Orders(); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { r.Add(Order.Random()); } return(r); }
public static Measures Random() { var m = new Measures(); var c = GetRandom.Count(2, 5); for (var i = 0; i < c; i++) { m.Add(Measure.Random()); } return(m); }
public static Inventory Random() { var a = new Inventory(); var b = GetRandom.Count(); for (var i = 0; i < b; i++) { a.Add(InventoryEntry.Random()); } return(a); }
[TestMethod] public void AttributesTest() { Assert.AreEqual(0, obj.Attributes.Count); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { var a = Attribute.Random(); a.EntityId = obj.UniqueId; Attributes.Instance.Add(a); } Assert.AreEqual(c, obj.Attributes.Count); }
[TestMethod] public void RolesTest() { Assert.AreEqual(0, Obj.Roles.Count); var c = GetRandom.Count(); for (var i = 0; i < c; i++) { var r = Role.Random(); r.PerformerId = Obj.UniqueId; Roles.Instance.Add(r); } Assert.AreEqual(c, Obj.Roles.Count); }