replay();
forceCacheClear();
Messages messages = source.getMessages(model, Locale.ENGLISH);
assertEquals(messages.get("color"), "color");
assertEquals(messages.get("framework"), "Tapestry");
// Check normal caching
assertSame(source.getMessages(model, Locale.ENGLISH), messages);
// Now, force a cache clear and retry.
forceCacheClear();
Messages messages2 = source.getMessages(model, Locale.ENGLISH);
// Check that a new Messages was created
assertNotSame(messages2, messages);
assertEquals(messages2.get("color"), "color");
assertEquals(messages2.get("framework"), "Tapestry");
verify();
}