If possible, Add the following to the input field. id="cmdDisc"
Its trying to find the button based on the id attribute. HTH. Nick > -----Original Message----- > From: Alasdair Young [mailto:[EMAIL PROTECTED] > Sent: Wednesday, February 09, 2005 10:53 AM > To: 'jwebunit-users@lists.sourceforge.net' > Subject: [Jwebunit-users] Issue with clickButton() > > > Very simple problem, but I can't seem to see what I'm doing wrong. > > I get the following error: > > junit.framework.AssertionFailedError: Button [cmdDisc] not found. > at > net.sourceforge.jwebunit.WebTester.assertButtonPresent(WebTest > er.java:580) > ... > > when I do this: > > clickButton("cmdDisc"); > > on a page with this in it: > > <input type="button" name="cmdDisc" value="Discretionary" > onclick='setType("discretionary")'/> > > > Am I missing something terribly obvious? Should I use > something else as the > buttonId? > > > All I can find in the API is: > > clickButton > > public void clickButton(java.lang.String buttonId) > > > Any ideas? > > - alasdair > > Alasdair Young > This email has been scanned by Postini. > For more information please visit http://www.postini.com > > > > ------------------------------------------------------- > SF email is sponsored by - The IT Product Guide > Read honest & candid reviews on hundreds of IT Products from > real users. > Discover which products truly live up to the hype. Start reading now. > http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click > _______________________________________________ > Jwebunit-users mailing list > Jwebunit-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/jwebunit-users > - - - - - - This e-mail message is intended only for the use of the individual or entity identified in the alias address of this message and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution of this e-mail message is strictly prohibited. If you have received this e-mail message in error, please notify the sender immediately by reply e-mail and delete this message from your system. Thank you. ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ Jwebunit-users mailing list Jwebunit-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jwebunit-users