remove use of ModuleManager constants on util test
@@ -25,7 +25,6 @@ import java.io.InputStream;
import java.util.List;
import org.apache.commons.io.IOUtils;
-import org.apache.wiki.modules.ModuleManager;
import org.jdom2.Element;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
@@ -34,16 +33,16 @@ public class XmlUtilTest {
@Test
public void testParseFromClasspath() {
- List< Element > elements = XmlUtil.parse( ModuleManager.PLUGIN_RESOURCE_LOCATION, "/modules/plugin" );
+ List< Element > elements = XmlUtil.parse( "ini/jspwiki_module.xml", "/modules/plugin" );
Assertions.assertEquals( 4, elements.size() ); // 2 on src/main/resources, another 2 on src/test/resources
- elements = XmlUtil.parse( ModuleManager.PLUGIN_RESOURCE_LOCATION, "/modules/filter" );
+ elements = XmlUtil.parse( "ini/jspwiki_module.xml", "/modules/filter" );
Assertions.assertEquals( 1, elements.size() );
- elements = XmlUtil.parse( ModuleManager.PLUGIN_RESOURCE_LOCATION, "/modules/editor" );
+ elements = XmlUtil.parse( "ini/jspwiki_module.xml", "/modules/editor" );
Assertions.assertEquals( 2, elements.size() );
- elements = XmlUtil.parse( ModuleManager.PLUGIN_RESOURCE_LOCATION, "/modules/heck" );
+ elements = XmlUtil.parse( "ini/jspwiki_module.xml", "/modules/heck" );
Assertions.assertEquals( 0, elements.size() );
elements = XmlUtil.parse( "doesnt/exist.this", "/modules/editor" );
@@ -52,7 +51,7 @@ public class XmlUtilTest {
elements = XmlUtil.parse( ( String )null, "/modules/editor" );
Assertions.assertEquals( 0, elements.size() );
- elements = XmlUtil.parse( ModuleManager.PLUGIN_RESOURCE_LOCATION, null );
+ elements = XmlUtil.parse( "ini/jspwiki_module.xml", null );
Assertions.assertEquals( 0, elements.size() );
elements = XmlUtil.parse( ClassUtil.MAPPINGS, "/classmappings/mapping" );
