Bugs item #1049592, was opened at 2004-10-18 23:27
Message generated for change (Settings changed) made by dashorst
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497982&aid=1049592&group_id=61302
Category: None
Group: Release 1.3
>Status: Pending
Resolution: Rejected
Priority: 5
Submitted By: Martijn Dashorst (dashorst)
Assigned to: Martijn Dashorst (dashorst)
Summary: Submitting form without submit button gives NPE
Initial Comment:
The following HTML makes JWebUnit choke with a
NullPointerException, when excercising the following
unittest.
public void testFoo() {
getTestContext().setBaseUrl("http://localhost:8081/jwebunit/Userlist/RajeshNair");
beginAt("report.htm");
submit(); // gives NullPointerException.
}
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01
Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<body>
<form method="post" name="Form0"
action="report.htm">
<input type="image" name="hiddenImgSubmit"
border="0"
src="/test/images/spacer.gif"
onfocus="window.focus()"
onclick="return true"
id="submit_View_Report"/>
<input type="image"
name="hiddenImgSubmit$0" border="0"
src="/test/images/spacer.gif"
onfocus="window.focus()"
onclick="return true"
id="submit_Archive_Report"/>
</form>
</body>
</html>
----------------------------------------------------------------------
Comment By: Martijn Dashorst (dashorst)
Date: 2004-10-18 23:30
Message:
Logged In: YES
user_id=695103
This was originally posted by Rajesh Nair on the user list.
There is actually something that goes awry in HTTPUnit. This
problem can be worked around by using:
clickButton("submit_View_Report");
instead of submit();
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497982&aid=1049592&group_id=61302
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Jwebunit-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development