public void AddStringElementTest() { Multiplicity <string> multiplicity = new Multiplicity <string>(); multiplicity.Insert("ololo"); Assert.IsTrue(multiplicity.ExistenceChecking("ololo")); }
public void AddIntElementTest() { Multiplicity <int> multiplicity = new Multiplicity <int>(); multiplicity.Insert(1); Assert.IsTrue(multiplicity.ExistenceChecking(1)); }
public void RemovingOfElementTest() { Multiplicity <int> multiplicity = new Multiplicity <int>(); multiplicity.Insert(1); multiplicity.RemovingOfElement(1); Assert.IsTrue(multiplicity.IsEmpty()); }
public void UnionTest() { Multiplicity <int> multiplicity1 = new Multiplicity <int>(); multiplicity1.Insert(1); Multiplicity <int> multiplicity2 = new Multiplicity <int>(); Multiplicity <int> result = new Multiplicity <int>(); result.Union(multiplicity1, multiplicity2); Assert.IsFalse(result.IsEmpty()); }
public void Intersection1Test() { Multiplicity <int> multiplicity1 = new Multiplicity <int>(); multiplicity1.Insert(1); Multiplicity <int> multiplicity2 = new Multiplicity <int>(); multiplicity2.Insert(2); Multiplicity <int> result = new Multiplicity <int>(); result.Insert(1234); result.Intersection(multiplicity1, multiplicity2); Assert.IsTrue(result.IsEmpty()); }