Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-4437

BaseWicketTester.clickLink() does not work with a ResourceLink

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.5.4
    • Fix Version/s: 1.5.6, 6.0.0-beta1
    • Component/s: wicket
    • Labels:
      None

      Description

      When using BaseWicketTester.clickLink() with ResourceLink, it does not work. Clicking link in server (Jetty) it works and opens the resource. See attached quickstart.

      @Test
      public void clickingLink()

      { // doesn't work tester.clickLink("download"); Assert.assertEquals(tester.getContentTypeFromResponseHeader(), "text/plain"); }

      @Test
      public void usingListener()

      { // works tester.executeListener(tester.getComponentFromLastRenderedPage("download"), IResourceListener.INTERFACE); Assert.assertEquals(tester.getContentTypeFromResponseHeader(), "text/plain"); }

        Attachments

        1. resourcelink.tar.gz
          19 kB
          Juha Syrjälä

          Issue Links

            Activity

              People

              • Assignee:
                mgrigorov Martin Tzvetanov Grigorov
                Reporter:
                jsyrjala Juha Syrjälä
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: