public void getTopTest() { SeqStack <string> seqStack = new SeqStack <string>(10); seqStack.push("A"); seqStack.push("B"); seqStack.push("C"); Assert.AreEqual(seqStack.getTop(), "C"); }
public void clearTest() { SeqStack <string> seqStack = new SeqStack <string>(10); seqStack.push("A"); seqStack.push("B"); seqStack.push("C"); seqStack.clear(); Assert.AreEqual(seqStack.isEmpty, true); }
public void pushTest() { SeqStack <string> seqStack = new SeqStack <string>(10); seqStack.push("A"); seqStack.push("B"); seqStack.push("C"); List <string> result = new List <string>() { "C", "B", "A" }; CollectionAssert.AreEqual(seqStack.display(), result); }