### Question:
TravelFactory implements Iterable<TravelStrategy> { public TravelStrategy get(TravelId id) throws NullPointerException { TravelStrategy strategy = allModules.get(id); if (strategy == null) { throw new NullPointerException(); } return strategy; } private  TravelFactory(); static TravelFactory getInstance(); @Override Iterator<TravelStrategy> iterator(); TravelStrategy get(TravelId id);  }### Answer:
@Test(expected = NullPointerException.class) public void testGetTravelStrategy() { TravelStrategy strategy = factory.get(null); Assert.assertNull(strategy); }