Package org.impalaframework.module.source

Examples of org.impalaframework.module.source.SingleStringModuleDefinitionSource


public class ModificationTestUtils {

    static RootModuleDefinition spec(String contextString, String definitionString) {
        String[] locations = contextString.split(",");
        SingleStringModuleDefinitionSource builder = new SingleStringModuleDefinitionSource(new SimpleRootModuleDefinition("project1", locations),
                definitionString);
        RootModuleDefinition rootModuleDefinition = builder.getModuleDefinition();
        return rootModuleDefinition;
    }
View Full Code Here


    private String rootModuleName = "project1";

    public void testEmptyString() {
        SimpleRootModuleDefinition rootDefinition = new SimpleRootModuleDefinition(rootModuleName , new String[] { "parent-context" });
        String moduleString = "";
        SingleStringModuleDefinitionSource builder = new SingleStringModuleDefinitionSource(rootDefinition, moduleString);
        RootModuleDefinition result = builder.getModuleDefinition();
        assertSame(result, rootDefinition);
    }
View Full Code Here

    }
   
    public void testModuleWithoutBeanSpec() {
        SimpleRootModuleDefinition rootDefinition = new SimpleRootModuleDefinition(rootModuleName, new String[] { "parent-context" });
        String moduleString = " example-hibernate , example-dao ";
        SingleStringModuleDefinitionSource builder = new SingleStringModuleDefinitionSource(rootDefinition, moduleString);
        RootModuleDefinition result = builder.getModuleDefinition();
        assertSame(result, rootDefinition);
        assertEquals(2, rootDefinition.getChildModuleNames().size());
        System.out.println(rootDefinition.getChildModuleNames());
        assertNotNull(result.getChildModuleDefinition("example-hibernate"));
        assertNotNull(result.getChildModuleDefinition("example-dao"));
View Full Code Here

TOP

Related Classes of org.impalaframework.module.source.SingleStringModuleDefinitionSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.