use of org.apache.wiki.TestEngine in project jspwiki by apache.
the class CommandResolverTest method setUp.
@Before
public void setUp() throws Exception {
Properties props = TestEngine.getTestProperties();
props.setProperty(WikiEngine.PROP_MATCHPLURALS, "yes");
m_engine = new TestEngine(props);
resolver = m_engine.getCommandResolver();
m_engine.saveText("SinglePage", "This is a test.");
m_engine.saveText("PluralPages", "This is a test.");
}
use of org.apache.wiki.TestEngine in project jspwiki by apache.
the class GroupCommandTest method setUp.
@Before
public void setUp() throws Exception {
Properties props = TestEngine.getTestProperties();
new TestEngine(props);
}
use of org.apache.wiki.TestEngine in project jspwiki by apache.
the class PageCommandTest method setUp.
@Before
public void setUp() throws Exception {
Properties props = TestEngine.getTestProperties();
testEngine = new TestEngine(props);
testEngine.saveText("TestPage", "This is a test.");
testPage = testEngine.getPage("TestPage");
}
use of org.apache.wiki.TestEngine in project jspwiki by apache.
the class FilterBeanTest method testDoGet.
@Test
public void testDoGet() throws WikiException, NotCompliantMBeanException {
testEngine = new TestEngine(props);
WikiContext context = new WikiContext(testEngine, new WikiPage(testEngine, "TestPage01"));
FilterBean pb = new FilterBean(testEngine);
String expectedHtml = "<div>" + "<h4>Filters</h4>" + "<table border=\"1\">" + "<tr><th>Name</th><th>Author</th><th>Notes</th></tr>" + "<tr><td>org.apache.wiki.filters.SpamFilter</td><td>Janne Jalkanen</td><td></td></tr>" + "</table>" + "</div>";
Assert.assertEquals(expectedHtml, pb.doGet(context));
}
use of org.apache.wiki.TestEngine in project jspwiki by apache.
the class RenderingManagerTest method setUp.
@Before
public void setUp() throws Exception {
CacheManager.getInstance().removeAllCaches();
Properties props = TestEngine.getTestProperties();
m_engine = new TestEngine(props);
m_manager = m_engine.getRenderingManager();
}
Aggregations