Issue Type: Bug Bug
Assignee: Oliver Gondža
Components: acceptance-test-harness
Created: 10/Dec/14 9:55 AM
Description:

Jenkins has its own HtmlUnit module, that is downloaded throught Maven as dependency to jenkins test harness. But the module is rather old (2.6).

This causes error while running JUnit tests

Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 19.895 sec <<< FAILURE! - in hudson.plugins.git.ui.ChangeSetListTest
test1(hudson.plugins.git.ui.ChangeSetListTest)  Time elapsed: 17.864 sec  <<< ERROR!
com.gargoylesoftware.htmlunit.ScriptException: TypeError: Cannot find function querySelectorAll in object [object HTMLDocument]. (script in http://localhost:48448/job/test0/1/ from (45, 21) to (65, 14)#47)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.constructError(ScriptRuntime.java:3652)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.constructError(ScriptRuntime.java:3630)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.typeError(ScriptRuntime.java:3658)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.typeError2(ScriptRuntime.java:3677)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.notFunctionError(ScriptRuntime.java:3741)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.getPropFunctionAndThisHelper(ScriptRuntime.java:2249)
        at net.sourceforge.htmlunit.corejs._javascript_.ScriptRuntime.getPropFunctionAndThis(ScriptRuntime.java:2216)

The method querySelectorAll() support has been added since 2.9 according to HtmlUnit change log.

Simple substitution of new HtmlUnit causes failure in WebClient (Jenkins') constructor, as BrowserVersion has been changed:

Tests in error:
  FailedTest.org.jvnet.hudson.test.JellyTestSuiteBuilder$JellyTestSuite »
NoSuchField
  PreBuildMergeOptionsTest.exporting:48 » NoSuchField FIREFOX_2
  GitSCMTest>HudsonTestCase.runBare:296->HudsonTestCase.runTest:440-
>testConfigRoundtripURLPreserved:1229->HudsonTestCase.configRoundtrip:888-
>HudsonTestCase.createWebClient:1617 » NoSuchField
  GitSCMTest>HudsonTestCase.runBare:296->HudsonTestCase.runTest:440-
>testConfigRoundtrip:1240->HudsonTestCase.configRoundtrip:888-
>HudsonTestCase.createWebClient:1617 » NoSuchField
Project: Jenkins
Priority: Minor Minor
Reporter: Pavel Baranchikov
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to