Preconditions { public boolean areSatisfied() { if (dirty) { satisfied = candidates.containsAll(preconditions); dirty = false; } return satisfied; }  void addPrecondition(String precondition); void clearPreconditions(); void addCandidate(String candidate); void removeCandidate(String candidate); boolean areSatisfied(); @Override String toString();  }
@Test public void testEmptyIsSatisfied() { assertTrue(preconditions.areSatisfied()); }