I am having a struts app with Jsp as my front end..I have javascripts in Jsp...I want to have javascript support to detect alert/confirm dialogs etc etc...
when I include js.jar in my classpath I get following error...Please help...
java.lang.RuntimeException: No such property: Parent
at com.meterware.httpunit.scripting.ScriptableDelegate.set(ScriptableDelegate.java:98)
at com.meterware.httpunit.WebResponse$Scriptable.set(WebResponse.java:683)
at com.meterware.httpunit._javascript._JavaScript$JavaScriptEngine.put(_JavaScript.java:265)
at org.mozilla._javascript.ScriptableObject.defineProperty(ScriptableObject.java:1077)
at org.mozilla._javascript.ScriptableObject.defineProperty(ScriptableObject.java:1103)
at org.mozilla._javascript.ScriptRuntime.initFunction(ScriptRuntime.java:1943)
at org.mozilla._javascript.optimizer.OptRuntime.initFunction(OptRuntime.java:310)
at org.mozilla._javascript.gen.c54.call(httpunit)
at org.mozilla._javascript.gen.c54.exec(httpunit)
at org.mozilla._javascript.Context.evaluateString(Context.java:781)
at com.meterware.httpunit._javascript._JavaScript$JavaScriptEngine.executeScript(_JavaScript.java:122)
at com.meterware.httpunit.scripting.ScriptableDelegate.runScript(ScriptableDelegate.java:64)
at com.meterware.httpunit.parsing.ScriptFilter.getTranslatedScript(ScriptFilter.java:150)
at com.meterware.httpunit.parsing.ScriptFilter.endElement(ScriptFilter.java:131)
at org.cyberneko.html.HTMLTagBalancer.endElement(Unknown Source)
at org.cyberneko.html.HTMLScanner$SpecialScanner.scan(Unknown Source)
at org.cyberneko.html.HTMLScanner.scanDocument(Unknown Source)
at org.cyberneko.html.HTMLConfiguration.parse(Unknown Source)
at org.cyberneko.html.HTMLConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at com.meterware.httpunit.parsing.NekoHTMLParser.parse(NekoHTMLParser.java:41)
at com.meterware.httpunit.HTMLPage.parse(HTMLPage.java:244)
at com.meterware.httpunit.WebResponse.getReceivedPage(WebResponse.java:1014)
at com.meterware.httpunit.WebResponse$Scriptable.load(WebResponse.java:611)
at com.meterware.httpunit._javascript._JavaScript$Window.initialize(_JavaScript.java:424)
at com.meterware.httpunit._javascript._JavaScript.run(_JavaScript.java:80)
at com.meterware.httpunit._javascript.JavaScriptEngineFactory.associate(JavaScriptEngineFactory.java:46)
at com.meterware.httpunit.RequestContext.runScripts(RequestContext.java:44)
at com.meterware.httpunit.WebWindow.getResponse(WebWindow.java:119)
at com.meterware.httpunit.WebClient.getResponse(WebClient.java:112)
at epm1Test.UserOrgsTest.testSiteOn(UserOrgsTest.java:51)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at junit.textui.TestRunner.doRun(TestRunner.java:116)
at com.intellij.rt.execution.junit2.IdeaJUnitAgent.doRun(Unknown Source)
at junit.textui.TestRunner.start(TestRunner.java:172)
at com.intellij.rt.execution.junit.TextTestRunner2.startRunnerWithArgs(Unknown Source)
at com.intellij.rt.execution.junit2.JUnitStarter.prepareStreamsAndStart(Unknown Source)
at com.intellij.rt.execution.junit2.JUnitStarter.main(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.intellij.rt.execution.application.AppMain.main(Unknown Source)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am having a struts app with Jsp as my front end..I have javascripts in Jsp...I want to have javascript support to detect alert/confirm dialogs etc etc...
when I include js.jar in my classpath I get following error...Please help...
java.lang.RuntimeException: No such property: Parent
at com.meterware.httpunit.scripting.ScriptableDelegate.set(ScriptableDelegate.java:98)
at com.meterware.httpunit.WebResponse$Scriptable.set(WebResponse.java:683)
at com.meterware.httpunit._javascript._JavaScript$JavaScriptEngine.put(_JavaScript.java:265)
at org.mozilla._javascript.ScriptableObject.defineProperty(ScriptableObject.java:1077)
at org.mozilla._javascript.ScriptableObject.defineProperty(ScriptableObject.java:1103)
at org.mozilla._javascript.ScriptRuntime.initFunction(ScriptRuntime.java:1943)
at org.mozilla._javascript.optimizer.OptRuntime.initFunction(OptRuntime.java:310)
at org.mozilla._javascript.gen.c54.call(httpunit)
at org.mozilla._javascript.gen.c54.exec(httpunit)
at org.mozilla._javascript.Context.evaluateString(Context.java:781)
at com.meterware.httpunit._javascript._JavaScript$JavaScriptEngine.executeScript(_JavaScript.java:122)
at com.meterware.httpunit.scripting.ScriptableDelegate.runScript(ScriptableDelegate.java:64)
at com.meterware.httpunit.parsing.ScriptFilter.getTranslatedScript(ScriptFilter.java:150)
at com.meterware.httpunit.parsing.ScriptFilter.endElement(ScriptFilter.java:131)
at org.cyberneko.html.HTMLTagBalancer.endElement(Unknown Source)
at org.cyberneko.html.HTMLScanner$SpecialScanner.scan(Unknown Source)
at org.cyberneko.html.HTMLScanner.scanDocument(Unknown Source)
at org.cyberneko.html.HTMLConfiguration.parse(Unknown Source)
at org.cyberneko.html.HTMLConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at com.meterware.httpunit.parsing.NekoHTMLParser.parse(NekoHTMLParser.java:41)
at com.meterware.httpunit.HTMLPage.parse(HTMLPage.java:244)
at com.meterware.httpunit.WebResponse.getReceivedPage(WebResponse.java:1014)
at com.meterware.httpunit.WebResponse$Scriptable.load(WebResponse.java:611)
at com.meterware.httpunit._javascript._JavaScript$Window.initialize(_JavaScript.java:424)
at com.meterware.httpunit._javascript._JavaScript.run(_JavaScript.java:80)
at com.meterware.httpunit._javascript.JavaScriptEngineFactory.associate(JavaScriptEngineFactory.java:46)
at com.meterware.httpunit.RequestContext.runScripts(RequestContext.java:44)
at com.meterware.httpunit.WebWindow.getResponse(WebWindow.java:119)
at com.meterware.httpunit.WebClient.getResponse(WebClient.java:112)
at epm1Test.UserOrgsTest.testSiteOn(UserOrgsTest.java:51)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at junit.textui.TestRunner.doRun(TestRunner.java:116)
at com.intellij.rt.execution.junit2.IdeaJUnitAgent.doRun(Unknown Source)
at junit.textui.TestRunner.start(TestRunner.java:172)
at com.intellij.rt.execution.junit.TextTestRunner2.startRunnerWithArgs(Unknown Source)
at com.intellij.rt.execution.junit2.JUnitStarter.prepareStreamsAndStart(Unknown Source)
at com.intellij.rt.execution.junit2.JUnitStarter.main(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.intellij.rt.execution.application.AppMain.main(Unknown Source)