public void RandomInverseTreapTest() { IInverseIntTreap <int> fst = new InverseIntTreap <int>(); IInverseIntTreap <int> snd = new TrivialImplementIInverseIntTreap(); GenerateTreap(fst, 42); GenerateTreap(snd, 42); Assert.That(EqInverseTreap(fst, snd)); }
public void Test() { InverseIntTreap <int> treap = new InverseIntTreap <int>(); for (int i = 0; i < 100; i++) { treap.Insert(i, i); } for (int i = 0; i < 100; i++) { Assert.AreEqual(treap.GetInverse(i), i); } }