-
-
Notifications
You must be signed in to change notification settings - Fork 107
Fix unit tests that fail due to jenkins CSS changes #184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix unit tests that fail due to jenkins CSS changes #184
Conversation
| <dependency> | ||
| <groupId>com.google.errorprone</groupId> | ||
| <artifactId>error_prone_annotations</artifactId> | ||
| <version>2.10.0</version> | ||
| </dependency> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was excluded for script-security do we need to version manage this or should it be excluded if coming from core via guava?
|
|
||
| HtmlPage configFiles = wc.goTo("configfiles"); | ||
| HtmlAnchor removeAnchor = configFiles.getDocumentElement().getFirstByXPath("//a[contains(@onclick, 'removeConfig?id=" + CONFIG_ID + "')]"); | ||
| HtmlAnchor removeAnchor = configFiles.getDocumentElement().getFirstByXPath("//a[contains(@data-url, 'removeConfig?id=" + CONFIG_ID + "')]"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HtmlAnchor removeAnchor = configFiles.getDocumentElement().getFirstByXPath("//a[contains(@data-url, 'removeConfig?id=" + CONFIG_ID + "')|contains(@onclick, 'removeConfig?id=" + CONFIG_ID + "')]");should (if I got my XPath correct) have allowed to fix a PCT issue without bumping the core to a non LTS making upgrades for LTS users harder.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
basically, your saying to make this test backwards compatible with older jenkins?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am saying you could have done that to make it backwards compatible with older Jenkins versions. As it is a test only issue and the plugin will work after an upgrade of Jenkins, the current way is not making it any harder for users (there would be no broken plugins post upgrade) so it is fine as is. (hence my approval)
|
@mikecirioli starting from your PR, I have created the PR #199 where I merged master and updated some dependencies because the build was failing due to Maven enforcer rule, so this PR becomes obsolete. |
|
Suggest closing in favor of #200. |
HTML element attribute id names have changed in newer versions of Jenkins (2.33x.x), causing a few unit tests to break. This PR updates and fixes them.