[Webtest] clicklink and clickbutton-no new response ...

Werner Koenig webtest@lists.canoo.com
Tue, 20 Jul 2004 10:17:58 +0200


Hallo,

when performing a click on a link or a button (see the following xml - I 
don't think it is wrong !?) id does not work: no new request is coming 
from the server.
In Server-debug-mode I did not see an incoming request.

<clicklink stepid="Detailinfo" label="Dr">
 or
<setinputfield name="nname" value="aName" />
<clickbutton stepid="submit masuche"
        label=" Suche starten ">
<form name="mitarbeitersuche" />
</clickbutton>
 I changed the code submitting the request in com.canoo.webtest.steps.request.ClickButton.java:

gotoTarget(...) {...
  WebRequest req = form.getRequest((SubmitButton)button);
  // original: 
setIntermediateResponse(context.getWebConversation().getCurrentPage());
  setIntermediateResponse(context.getWebConversation().getResponse(req));
...}

and in ClickLink:
 doExecute(...) {...
                        prepareConversation(context);
                                theLink.click();
                                WebConversation wc = 
context.getWebConversation();
                                wc.sendRequest(theLink.getRequest());
                                WebResponse resp = wc.getCurrentPage();
...}

before it was only         WebResponse resp = theLink.click(); 

and now it works !?!?

some ideas?

Many thanks!


Werner