Examples of ContributionDef


Examples of org.apache.tapestry5.ioc.def.ContributionDef

        configuration.add("fred", service);

        replay();

        Method m = findMethod("contributeOrderedParameter");
        ContributionDef def = new ContributionDefImpl("foo.Bar", m, false, null, null, null);

        def.contribute(this, resources, configuration);

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

        configuration.add("fred", service);

        replay();

        Method m = findMethod("contributeOrderedParameterNamedServiceLookup");
        ContributionDef def = new ContributionDefImpl("foo.Bar", m, false, null, null, null);

        def.contribute(this, resources, configuration);

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

        configuration.add("upcase", service);

        replay();

        Method m = findMethod("contributeMappedParameter");
        ContributionDef def = new ContributionDefImpl("foo.Bar", m, false, null, null, null);

        def.contribute(this, resources, configuration);

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

        configuration.add("upcase", service);

        replay();

        Method m = findMethod("contributeMappedParameterNamedServiceLookup");
        ContributionDef def = new ContributionDefImpl("foo.Bar", m, false, null, null, null);

        def.contribute(this, resources, configuration);

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    private static final String SERVICE_ID = "Baz";

    @Test
    public void proper_key_and_value()
    {
        ContributionDef def = mockContributionDef();
        Map<Class, ContributionDef> keyToContribution = newMap();
        ObjectLocator locator = mockObjectLocator();
        Map<Class, Runnable> map = CollectionFactory.newMap();
        TypeCoercerProxy tc = mockTypeCoercerProxy();
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    }

    @Test
    public void coerced_value()
    {
        ContributionDef def = mockContributionDef();
        Map<Class, ContributionDef> keyToContribution = newMap();
        ObjectLocator locator = mockObjectLocator();
        Map<Class, Runnable> map = CollectionFactory.newMap();
        TypeCoercerProxy tc = mockTypeCoercerProxy();
        String contributedValue = "coerceme";
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    }

    @Test
    public void duplicate_key()
    {
        ContributionDef def1 = newContributionDef("contributionPlaceholder1");
        ContributionDef def2 = newContributionDef("contributionPlaceholder2");
        Map<Class, ContributionDef> keyToContribution = newMap();
        ObjectLocator locator = mockObjectLocator();
        Map<Class, Runnable> map = CollectionFactory.newMap();
        TypeCoercerProxy tc = mockTypeCoercerProxy();
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    }

    @Test
    public void null_key()
    {
        ContributionDef def = newContributionDef("contributionPlaceholder1");
        Map<Class, ContributionDef> keyToContribution = newMap();
        Runnable value = mockRunnable();
        ObjectLocator locator = mockObjectLocator();
        Map<Class, Runnable> map = CollectionFactory.newMap();
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    @SuppressWarnings("unchecked")
    @Test
    public void wrong_key_type()
    {
        ContributionDef def = newContributionDef("contributionPlaceholder1");
        Map<?, ContributionDef> keyToContribution = CollectionFactory.newMap();
        Runnable value = mockRunnable();
        ObjectLocator locator = mockObjectLocator();
        Map<Class, Runnable> map = CollectionFactory.newMap();
View Full Code Here

Examples of org.apache.tapestry5.ioc.def.ContributionDef

    }

    @Test
    public void null_value()
    {
        ContributionDef def = newContributionDef("contributionPlaceholder1");
        Map<Class, ContributionDef> keyToContribution = CollectionFactory.newMap();
        Map<Class, Runnable> map = CollectionFactory.newMap();
        ObjectLocator locator = mockObjectLocator();

        replay();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.