public static void ContainsTest() { var stack = new ListBasedStack <int>(new[] { 0, 1, 2, 3, 4 }); Assert.IsTrue(stack.Contains(0)); Assert.IsTrue(stack.Contains(1)); Assert.IsTrue(stack.Contains(2)); Assert.IsTrue(stack.Contains(3)); Assert.IsTrue(stack.Contains(4)); }
public static void ContainsTest() { var stack = new ListBasedStack <int>(new[] { 0, 1, 2, 3, 4 }); Assert.Multiple(() => { stack.Contains(0).Should().BeTrue(); stack.Contains(1).Should().BeTrue(); stack.Contains(2).Should().BeTrue(); stack.Contains(3).Should().BeTrue(); stack.Contains(4).Should().BeTrue(); }); }