public class DummyDriver { public static void main (String [] args) { //test constructor DropoutStack myStack = new DropoutStack( ); System.out.println("New DropoutStack has been successfully created."); //test push Integer i = new Integer(187); myStack.push(i); System.out.println("New element has been pushed onto the DropoutStack successfully."); //test size try{ System.out.println("The current size of the DropoutStack after the push is: " + myStack.size());} catch (Exception e){ System.out.println("The size method does not work correctly."); } //test pop try{ myStack.pop( ); System.out.println("The top element of the DropoutStack has been popped successfully."); System.out.println("The current size of the DropoutStack after the pop is: " + myStack.size());} catch (Exception e){ System.out.println("The DropoutStack cannot be popped successfully, there is an error in your code.");} //test empty if (myStack.isEmpty( )) System.out.println("The DropoutStack is now empty."); //test peek try{ myStack.peek();} catch (EmptyCollectionException e) { System.out.println("Peek of the empty DropoutStack has caused the correct exception.");} catch (Exception e) { System.out.println("Peek of the empty DropoutStack throws an incorrect exception or peek does not work correctly.");} } }