// first template
final Iterator templateIterator = resources.iterator();
Resource resource = (Resource)templateIterator.next();
assertTrue(resource.isLastModifiedCheck());
Template template = (Template)templateIterator.next();
assertEquals(
"EntityBean.vsl",
template.getPath());
assertEquals(
"{0}/{1}Bean.java",
template.getOutputPattern());
assertEquals(
"beans",
template.getOutlet());
assertTrue(template.isOverwrite());
assertNotNull(template.getSupportedModeElements());
assertEquals(
"entity",
template.getSupportedModeElements().getVariable());
Collection modelElements = template.getSupportedModeElements().getModelElements();
assertNotNull(modelElements);
assertEquals(
1,
modelElements.size());
ModelElement element = (ModelElement)modelElements.iterator().next();
assertEquals(
"Entity",
element.getStereotype());
// second template
template = (Template)templateIterator.next();
assertEquals(
"templates/webservice/axis/server-config.wsdd.vsl",
template.getPath());
assertEquals(
"WEB-INF/server-config.wsdd",
template.getOutputPattern());
assertEquals(
"axis-configuration",
template.getOutlet());
assertEquals("$viewType.equals('jsp')", template.getOutputCondition());
assertTrue(template.isOverwrite());
assertTrue(template.isOutputToSingleFile());
assertFalse(template.isOutputOnEmptyElements());
assertNotNull(template.getSupportedModeElements());
assertEquals(
"services",
template.getSupportedModeElements().getVariable());
modelElements = template.getSupportedModeElements().getModelElements();
assertNotNull(modelElements);
assertEquals(
1,
modelElements.size());
element = (ModelElement)modelElements.iterator().next();