@Test public void getTemplateName() { assertEquals(null, content.getTemplateName()); content.setTemplate(" test.vm "); assertEquals("test.vm", content.getTemplateName()); }
@Test public void getPullService() { assertSame(null, content.getPullService()); content.setPullService(pullService); assertSame(pullService, content.getPullService()); }
@Test public void getTemplateService() { try { content.getTemplateService(); fail(); } catch (IllegalArgumentException e) { assertThat(e, exception("templateService")); } content.setTemplateService(templateService); assertSame(templateService, content.getTemplateService()); }
protected final void initContent( TC content, boolean withTemplateService, boolean withPullService) { this.content = content; builder.setContent(content); if (withTemplateService) { content.setTemplateService(templateService); } if (withPullService) { content.setPullService(pullService); } }
protected final void initContent( String templateName, boolean withTemplateService, boolean withPullService) { initContent(createContent(), withTemplateService, withPullService); if (templateName != null) { content.setTemplate(templateName); } }