Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

iframe not supported for jwebUnit

y spektory
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
any of you know jWebUnit or HttpUnit?

i am running a very simple code (here is a snippet)
the html code is this:

the iframe is this:

<form action="TypeMultiple.jsp" method="post" name="stuffform">
<input type="checkbox" name="is_correct" value="1" >
correct answer

<input type="submit" name="Submit" class=button value="submit">

the root frame includes:

<iframe name="addanswer" src="../cms/TypeMultiple.jsp?&redirected=1" width="100%" height="500" marginwidth=0 marginheight=0 frameborder=0 scrolling=yes></iframe>

the jWebUnit code includes this:

assertFramePresent("addanswer");//not needed, but i wanted to be sure

this works fine, but when i add:
it fails either because :

net.sourceforge.jwebunit.UnableToSetFormException: Attempted to set form to null.
at net.sourceforge.jwebunit.HttpUnitDialog.setWorkingForm(


junit.framework.AssertionFailedError: Did not find form element with name [is_correct].

i have searched through the documetnation and saw there was a patch for iframe in the case of onload() on the previous release, but it doesn't solve my problem.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic