I am new to HTTPUnit but am very impressed so far. My problem is concerned with HTTPUnit throwing an exception when it tries to parse a web that has invalid javascript code in it. I know this is meant to be a good thing because HTTPUnit is meant to detect errors but is there a way of telling HTTPUnit to skip Javascript parsing all together?
Mark
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi all,
I am new to HTTPUnit but am very impressed so far. My problem is concerned with HTTPUnit throwing an exception when it tries to parse a web that has invalid javascript code in it. I know this is meant to be a good thing because HTTPUnit is meant to detect errors but is there a way of telling HTTPUnit to skip Javascript parsing all together?
Mark
Yes, call the static method
HttpUnitOptions.setScriptingEnabled(false);
Or, to simply turn of the throwing of exceptions (that way you can still run scripts, but not have it stop your test) call:
HttpUnitOptions.setExceptionsThrownOnScriptError(false);