public void testNeedsNewVersionChangedTemplateOk() throws Exception {
final VelocityArtifactPreprocessor vap = createProcessor();
String url = createArtifact("Message: [$context.msg]");
vap.preprocess(url, m_resolver, TARGET, VERSION1, m_obrUrl);
boolean result = vap.needsNewVersion(url, m_resolver, TARGET, VERSION1);
assertFalse(result); // no new version is needed...
updateArtifact(url, "Another message: [$context.msg2]");
result = vap.needsNewVersion(url, m_resolver, TARGET, VERSION1);
assertFalse(result); // no new version is needed; original artifact is cached indefinitely...
}
|