This PR has been in development/hiatus/redevelopment for a while. I'm stuck on a few tests with a variation on the failure of matrix creation within a matrix job:
Jul 11, 2016 9:24:04 PM com.gargoylesoftware.htmlunit.javascript.background.JavaScriptJobManagerImpl runSingleJob
SEVERE: Job run failed with unexpected RuntimeException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
======= EXCEPTION START ========
Exception class=[net.sourceforge.htmlunit.corejs.javascript.JavaScriptException]
com.gargoylesoftware.htmlunit.ScriptException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:865)
at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:628)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:513)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine.callFunction(JavaScriptEngine.java:796)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.setState(XMLHttpRequest.java:224)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.doSend(XMLHttpRequest.java:775)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.access$000(XMLHttpRequest.java:105)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest$1.run(XMLHttpRequest.java:630)
at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:628)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:513)
at com.gargoylesoftware.htmlunit.javascript.background.JavascriptXMLHttpRequestJob.run(JavascriptXMLHttpRequestJob.java:37)
at com.gargoylesoftware.htmlunit.javascript.background.JavaScriptJobManagerImpl.runSingleJob(JavaScriptJobManagerImpl.java:428)
at com.gargoylesoftware.htmlunit.javascript.background.DefaultJavaScriptExecutor.run(DefaultJavaScriptExecutor.java:168)
at java.lang.Thread.run(Thread.java:745)
Caused by: net.sourceforge.htmlunit.corejs.javascript.JavaScriptException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpretLoop(Interpreter.java:1006)
at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpret(Interpreter.java:798)
at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.call(InterpretedFunction.java:105)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.doTopCall(ContextFactory.java:411)
at com.gargoylesoftware.htmlunit.javascript.HtmlUnitContextFactory.doTopCall(HtmlUnitContextFactory.java:310)
at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3286)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$4.doRun(JavaScriptEngine.java:789)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:850)
... 13 more
JavaScriptException value = TypeError: Cannot find function on in object [object HTMLSpanElement].
== CALLING JAVASCRIPT ==
function ()
{ var a = merge(args, arguments); return __method.apply(context, a); }
======= EXCEPTION END ========
While this error makes sense, I'm not sure how to solve it. I know it's tied to how the selection is made on the page, and think it's something in the processing of the "onClick" function. Disabling Javascript isn't helpful since the entire creation process is handled in Javascript.
The real goal for this plugin change is to make testing easier. If the parent is changed to the jenkins-test-harness things like the plugin-compat-test would be able to check it against other versions of Jenkins fairly easily.
If anyone knows a good way around the above error or have a suggestion, please let me know. All comments are welcome.
This PR has been in development/hiatus/redevelopment for a while. I'm stuck on a few tests with a variation on the failure of matrix creation within a matrix job:
{ var a = merge(args, arguments); return __method.apply(context, a); }Jul 11, 2016 9:24:04 PM com.gargoylesoftware.htmlunit.javascript.background.JavaScriptJobManagerImpl runSingleJob
SEVERE: Job run failed with unexpected RuntimeException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
======= EXCEPTION START ========
Exception class=[net.sourceforge.htmlunit.corejs.javascript.JavaScriptException]
com.gargoylesoftware.htmlunit.ScriptException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:865)
at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:628)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:513)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine.callFunction(JavaScriptEngine.java:796)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.setState(XMLHttpRequest.java:224)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.doSend(XMLHttpRequest.java:775)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest.access$000(XMLHttpRequest.java:105)
at com.gargoylesoftware.htmlunit.javascript.host.xml.XMLHttpRequest$1.run(XMLHttpRequest.java:630)
at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:628)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:513)
at com.gargoylesoftware.htmlunit.javascript.background.JavascriptXMLHttpRequestJob.run(JavascriptXMLHttpRequestJob.java:37)
at com.gargoylesoftware.htmlunit.javascript.background.JavaScriptJobManagerImpl.runSingleJob(JavaScriptJobManagerImpl.java:428)
at com.gargoylesoftware.htmlunit.javascript.background.DefaultJavaScriptExecutor.run(DefaultJavaScriptExecutor.java:168)
at java.lang.Thread.run(Thread.java:745)
Caused by: net.sourceforge.htmlunit.corejs.javascript.JavaScriptException: TypeError: Cannot find function on in object [object HTMLSpanElement]. (http://localhost:46836/jenkins/static/b7504d27/scripts/hudson-behavior.js#2806)
at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpretLoop(Interpreter.java:1006)
at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpret(Interpreter.java:798)
at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.call(InterpretedFunction.java:105)
at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.doTopCall(ContextFactory.java:411)
at com.gargoylesoftware.htmlunit.javascript.HtmlUnitContextFactory.doTopCall(HtmlUnitContextFactory.java:310)
at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3286)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$4.doRun(JavaScriptEngine.java:789)
at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:850)
... 13 more
JavaScriptException value = TypeError: Cannot find function on in object [object HTMLSpanElement].
== CALLING JAVASCRIPT ==
function ()
======= EXCEPTION END ========
While this error makes sense, I'm not sure how to solve it. I know it's tied to how the selection is made on the page, and think it's something in the processing of the "onClick" function. Disabling Javascript isn't helpful since the entire creation process is handled in Javascript.
The real goal for this plugin change is to make testing easier. If the parent is changed to the jenkins-test-harness things like the plugin-compat-test would be able to check it against other versions of Jenkins fairly easily.
If anyone knows a good way around the above error or have a suggestion, please let me know. All comments are welcome.