Beispiel #1
0
        public void Handle_Remove_Limit()
        {
            MyStack <int> stack = new MyStack <int>(3);

            Assert.Throws <CustomException>(() => stack.Remove());
        }
Beispiel #2
0
        public void Get_Last_Element_Exception()
        {
            var mystack = new MyStack <int>(3);

            Assert.Throws <CustomException>(() => mystack.GetLastElement());
        }
Beispiel #3
0
        public void Create()
        {
            MyStack <int> stack = new MyStack <int>(3);

            Assert.AreEqual(0, stack.Size);
        }