Example #1
0
        public void Push()
        {
            var stack = new StackUsingArray <int>();

            stack.Push(1);
            stack.Push(2);
            stack.Push(3);

            Assert.That(stack.Peek(), Is.EqualTo(3));
        }
Example #2
0
        public void Resize()
        {
            var stack = new StackUsingArray <int>();

            for (int i = 1; i <= 100; i++)
            {
                stack.Push(i);
            }

            Assert.That(stack.Peek(), Is.EqualTo(100));
        }