Example #1
0
        public void New_created_stack_have_not_elements()
        {
            MyStack <int> stack = new MyStack <int>();

            Assert.AreEqual(0, stack.Count());
        }
Example #2
0
        public void Peak_empty_stack_throw_exception()
        {
            MyStack <int> stack = new MyStack <int>();

            Assert.Catch <InvalidOperationException>(() => stack.Peak());
        }
Example #3
0
        public void New_created_stack_is_empty()
        {
            MyStack <int> stack = new MyStack <int>();

            Assert.IsTrue(stack.IsEmpty());
        }