Пример #1
0
 /**
  * Check that a newly created stack isn't full, and doesn't become full when we push several
  * things on it. In fact _no_ stack in this implementation should ever be full.
  *
  * <p>Note that this is a <em>classic</em> example of how testing can never <em>prove</em> that
  * code is correct. No matter how many items we push on this stack, we can never be sure that it
  * we just pushed <em>one</em> more on we could cause full to return true.
  */
 @Ignore
 @Test
 public void testIsFull() {
   final StackIF<Integer> stack = makeIntegerStack();
   assertFalse("Stacks should never be full", stack.isFull());
   for (int i = 0; i < 100; ++i) {
     stack.push(i);
     assertFalse("Stacks should never be full", stack.isFull());
   }
 }