Ejemplo n.º 1
0
 public void TestIsProperSubsetOf()
 {
     var a = new RedBlackSetTester<int>();
     Assert.That(() => a.IsProperSubsetOf(null), Throws.InstanceOf<ArgumentNullException>());
     Assert.That(a.IsProperSubsetOf(Enumerable.Range(1, 1)));
     Assert.That(a.IsProperSubsetOf(Enumerable.Empty<int>()), Is.False);
     a.AddRange(_primes);
     Assert.That(a.IsProperSubsetOf(_numbers));
     a.AddRange(_even.Where(UpTo100));
     Assert.That(a.IsProperSubsetOf(_numbers));
     a.AddRange(_odd.Where(UpTo100));
     Assert.That(a.IsProperSubsetOf(_numbers), Is.False);
 }