Package org.apache.tapestry5.ioc.services

Examples of org.apache.tapestry5.ioc.services.ClassNameLocator


    @Test
    public void page_found_in_core_lib()
    {
        String className = CORE_ROOT_PACKAGE + ".pages.MyCorePage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, CORE_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here


    @Test
    public void page_class_name_resolved_to_core_page()
    {
        String className = CORE_ROOT_PACKAGE + ".pages.MyCorePage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, CORE_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here

    @Test
    public void page_found_in_library()
    {
        String className = LIB_ROOT_PACKAGE + ".pages.MyLibPage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, LIB_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here

    @Test
    public void slashes_trimmed_from_library_prefix()
    {
        String className = LIB_ROOT_PACKAGE + ".pages.MyLibPage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, LIB_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here

    @Test
    public void lookup_by_logical_name_is_case_insensitive()
    {
        String className = LIB_ROOT_PACKAGE + ".pages.MyLibPage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, LIB_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here

    @Test
    public void name_stripping_includes_library_folder()
    {
        String className = LIB_ROOT_PACKAGE + ".pages.LibPage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, LIB_ROOT_PACKAGE + ".pages", className);

        replay();
View Full Code Here

    }

    @Test
    public void class_name_does_not_resolve_to_page_name()
    {
        ClassNameLocator locator = newClassNameLocator();
        Logger logger = mockLogger();

        replay();

        ComponentClassResolver resolver = create(logger, locator, new LibraryMapping(CORE_PREFIX, CORE_ROOT_PACKAGE));
View Full Code Here

    }

    @Test
    public void page_name_to_canonicalize_does_not_exist()
    {
        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, APP_ROOT_PACKAGE + ".pages", APP_ROOT_PACKAGE + ".pages.Start");

        replay();
View Full Code Here

    }

    @Test
    public void class_name_not_in_a_pages_package()
    {
        ClassNameLocator locator = newClassNameLocator();
        Logger logger = mockLogger();

        replay();

        ComponentClassResolver resolver = create(logger, locator, new LibraryMapping(CORE_PREFIX, CORE_ROOT_PACKAGE));
View Full Code Here

    public void multiple_mappings_for_same_prefix()
    {
        String secondaryLibPackage = "org.examples.addon.lib";
        String className = secondaryLibPackage + ".pages.MyLibPage";

        ClassNameLocator locator = newClassNameLocator();
        Logger logger = compliantLogger();

        train_locateComponentClassNames(locator, secondaryLibPackage + ".pages", className);

        replay();
View Full Code Here

TOP

Related Classes of org.apache.tapestry5.ioc.services.ClassNameLocator

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.