Package org.apache.tapestry5

Examples of org.apache.tapestry5.ComponentResources


  
   @Test
   public void check_add_javascript_calls_component_resources_to_create_url()
   {
      Object [] context = new Object[]{ "something", "somewhere" };
      ComponentResources resources = mockComponentResources();
      JavaScriptSupport javaScriptSupport = mockJavaScriptSupport();
      Link link = mockLink();
     
      Zone zone = mockZone();
     
      ZoneRefresh zoneRefresh = new ZoneRefresh(context, resources, javaScriptSupport, zone);
     
      expect(resources.createEventLink("zoneRefresh", context)).andReturn(link);
      expect(link.toAbsoluteURI()).andReturn("mylink");
     
      JSONObject params = new JSONObject();
      params.put("period", 0);
      params.put("id", zone.getClientId());
View Full Code Here


    @Test
    public void method_not_found_in_preamble()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void method_not_found_in_terminal()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void void_method_in_preamble()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void void_method_as_terminal()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void property_path_through_missing_property()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void property_path_through_write_only_property()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();

        train_getComponent(resources, bean);

        replay();
View Full Code Here

    @Test
    public void primitive_property()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = newComponentResources(bean);
        Location l = mockLocation();

        replay();

        Binding binding = factory.newBinding("test binding", resources, null, "intValue", l);
View Full Code Here

    @Test
    public void read_only_property()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = newComponentResources(bean);
        Location l = mockLocation();

        replay();

        Binding binding = factory.newBinding("test binding", resources, null, "readOnly", l);
View Full Code Here

    @Test
    public void write_only_property()
    {
        TargetBean bean = new TargetBean();
        ComponentResources resources = newComponentResources(bean);
        Location l = mockLocation();

        replay();

        Binding binding = factory.newBinding("test binding", resources, null, "writeOnly", l);
View Full Code Here

TOP

Related Classes of org.apache.tapestry5.ComponentResources

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.