Commit Graph
1218 Commits
Author SHA1 Message Date
Basil Crow 632033d6ad Sort imports (#5732) 2021-09-18 09:39:42 +01:00
ca0508eaa9 [JENKINS-66563] add a supported API for a plugin to insert jars into its classpath (#5711)
* Revive support for `URLClassLoader`

* [JENKINS-66563] add a supported API for a plugin to insert jars into its classpath

Required for BouncyCastle plugin so it does not try and expose its
classes when running in a JVM in FIPS mode, but can be other use cases
as yet unknown.

* [JENKINS-66563] add test case for new functionality

* [JENKINS-66563] and @since javadoc

* [JENKINS-66563] correct indent for new test

* mark the API Beta and document do not do this

Feedback from Jesse was we should be clearer that you probably should
not be using this interface and that there are other approaches that
should be used first.
To that end add some extra Javadoc and mark the API as Beta

* [JENKINS-66563] fix javadoc errors

* Fix typo

Co-authored-by: Devin Nusbaum <dwnusbaum@users.noreply.github.com>

Co-authored-by: Basil Crow <me@basilcrow.com>
Co-authored-by: Tim Jacomb <timjacomb1+github@gmail.com>
Co-authored-by: Tim Jacomb <21194782+timja@users.noreply.github.com>
Co-authored-by: Devin Nusbaum <dwnusbaum@users.noreply.github.com>
2021-09-16 08:09:46 +01:00
James NordandMark Waite 76a9dac136 Prevent Junit 4 tests from being skipped due to jupiter engine (#5713)
* Prevent Junit 4 tests from being skipped due to jupiter engine

@jglick suggested before when this happened we should have a check but I
never implemented it.
now it has happened again lets add the checj to make sure tests do not
get skipped withouth anyone realising because we accidently pull in
jupiter-engine.

* Update core/src/test/java/jenkins/Junit4TestsRanTest.java

Co-authored-by: Mark Waite <mark.earl.waite@gmail.com>

* test case needs to be public!

* the missing tests where from the test package

The tests not being executied due to #5703 where in the test package, so
add a test and check there too.

Co-authored-by: Mark Waite <mark.earl.waite@gmail.com>
2021-09-09 14:12:30 +02:00
Basil Crow 528d065ff5 Minor code cleanup (#5708) 2021-09-07 08:09:52 +01:00
Basil Crowanddependabot[bot] 3516369a78 Bump XStream from 1.4.17 to 1.4.18 (#5685)
* Bump xstream from 1.4.17 to 1.4.18

Bumps [xstream](https://github.com/x-stream/xstream) from 1.4.17 to 1.4.18.
- [Release notes](https://github.com/x-stream/xstream/releases)
- [Commits](https://github.com/x-stream/xstream/commits)

---
updated-dependencies:
- dependency-name: com.thoughtworks.xstream:xstream
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Adapting `hudson.util.RobustReflectionConverterTest.ifWorkaroundNeeded`.

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-08-31 07:43:58 +02:00
Brady ShoberandWadeck Follonier 471f7c38c8 Encode special characters for generated shell command (#5636)
Co-authored-by: Wadeck Follonier <Wadeck@users.noreply.github.com>
2021-08-24 07:59:54 +01:00
offa d37a460c84 Exception tests modernized. 2021-07-13 16:48:11 +02:00
Raihaan Shouhell bf01f36e75 Merge pull request #5602 from offa/dev
Exception test modernization / clean up
2021-07-10 00:38:12 +08:00
Raihaan Shouhell 8ea9db2e46 Merge pull request #5566 from basil/SubClassGenerator
Removing `SubClassGenerator`
2021-07-10 00:38:04 +08:00
offa aa1f5ccbf3 Code clean up. 2021-07-01 17:26:42 +02:00
offa 7143bf7c24 Commented out code removed. 2021-07-01 17:15:05 +02:00
offa 7ff32dcf3b Exception tests modernized and some code cleanup. 2021-07-01 17:14:43 +02:00
Basil Crow bd7c823c27 Remove unnecessary parentheses (#5576) 2021-06-25 09:23:37 +01:00
Basil Crow 2e8b3a92b0 Removing SubClassGenerator 2021-06-20 08:59:24 -07:00
Daniel Beck 239a6e635c Terminology cleanup: Internal and Javadoc changes 2021-06-20 16:24:43 +02:00
Basil Crow 3542eed78e Prefer ArrayList and ArrayDeque to LinkedList (#5553) 2021-06-14 16:46:01 +01:00
Basil CrowandDaniel Beck b8c20c6428 Fix violations of a handful of Error Prone checks (#5519)
Co-authored-by: Daniel Beck <1831569+daniel-beck@users.noreply.github.com>
2021-06-14 16:45:34 +01:00
olivier lamy a376fa2ca4 remove Digester from core
Signed-off-by: olivier lamy <olamy@apache.org>
2021-06-02 08:13:49 +10:00
Daniel BeckandDaniel Beck 09c269b0a2 Remove Arabic and Portuguese translations (#5518)
* Remove Arabic and Portuguese translations

* Fix test

Co-authored-by: Daniel Beck <daniel-beck@users.noreply.github.com>
2021-06-01 07:21:22 +02:00
Basil Crow 9f9ed7b60d Fix BadImport Error Prone violations (#5510)
* Fix `BadImport` Error Prone violations

* Fix Javadoc
2021-06-01 13:02:48 +08:00
Basil CrowandDaniel Beck 7f382b576e Fix CatchAndPrintStackTrace, CatchFail, and EmptyCatch Error Prone violations in tests (#5522)
Co-authored-by: Daniel Beck <1831569+daniel-beck@users.noreply.github.com>
2021-05-25 20:51:14 +01:00
Basil Crow 52acfa962f Remove usages of deprecated (in Java 9 and above) Class#newInstance (#5483)
* Remove usages of deprecated (in Java 9 and above) `Class#newInstance`

* Improve catching of InvocationTargetException

* Use AssertionError where appropriate
2021-05-16 07:27:32 +02:00
Basil Crow 3515c7a4e8 Remove Guava test library (#5468) 2021-05-11 08:12:09 +01:00
Oleg Nenashev 22fcc54bd3 Merge pull request #5451 from basil/checkstyle
Enable `AnnotationUseStyle`, `AvoidNoArgumentSuperConstructorCall`, and `NoEnumTrailingComma` Checkstyle checks
2021-05-10 11:40:54 +02:00
Oleg Nenashev 85eed765e1 Merge pull request #5469 from basil/endWithNewline
Ensure files end with a newline with Spotless rather than Checkstyle
2021-05-10 11:40:39 +02:00
Basil Crow c904989067 Deprecate Util#join(Collection, String) in favor of String#join(CharSequence, Iterable) (#5467) 2021-05-09 08:08:59 +01:00
Basil Crow 56216ba477 Ensure files end with a newline with Spotless rather than Checkstyle 2021-05-07 19:56:27 -07:00
Tim Jacomb c754339734 Merge pull request #5438 from basil/checkstyle-tests 2021-05-07 21:07:03 +01:00
Stefan Spieker f1867892fd removed unused import 2021-05-02 09:38:41 +02:00
Stefan Spieker afd748142e removed superfluous throws in tests 2021-05-02 00:16:50 +02:00
Basil Crow a464cf85a4 Enable AnnotationUseStyle Checkstyle check 2021-04-28 08:31:30 -07:00
Basil Crow 95e85495ca Enable AvoidStarImport Checkstyle check (#5420) 2021-04-28 17:28:39 +08:00
Basil Crow f6378676b1 Add missing @Override annotations (#5430) 2021-04-28 17:28:25 +08:00
Basil Crow 8d164663c4 [JENKINS-52356] Support ZIP64 in ZipArchiver (#5435)
* [JENKINS-52356] Support ZIP64 in ZipArchiver

* Fix resource leak
2021-04-24 10:59:11 +02:00
Basil Crow 5c4701eb83 Fix RedundantModifier Checkstyle violations in tests 2021-04-19 14:21:31 -07:00
Basil Crow 7268f7a073 Fix IllegalImport Checkstyle violation in tests 2021-04-19 14:21:31 -07:00
Basil Crow 2428e0c3b3 Fix OneStatementPerLine Checkstyle violations in tests 2021-04-19 14:21:31 -07:00
Basil Crow 08af6df395 Fix OneTopLevelClass Checkstyle violation in tests 2021-04-19 14:21:31 -07:00
Basil Crow d84bc82979 Fix NewlineAtEndOfFile Checkstyle violations in tests 2021-04-19 14:21:31 -07:00
Oleg Nenashev 0fd55bd6b5 Merge pull request #5419 from basil/subtypes
Use declaring class as qualifier
2021-04-19 22:54:17 +02:00
Oleg Nenashev 8f14137c63 Merge pull request #5432 from daniel-beck/jira-references
Update Jira references from HUDSON to JENKINS
2021-04-19 22:52:19 +02:00
Daniel Beck 5479432ee7 Update Jira references from HUDSON to JENKINS 2021-04-17 23:27:58 +02:00
Basil Crow 10d8245064 Remove unused imports 2021-04-14 18:15:43 -07:00
Basil Crow 583ba94524 Change indirect accesses to static members to direct accesses (accesses through subtypes) 2021-04-14 17:36:23 -07:00
Basil Crow 30f61ce7d6 Reduce usages of com.google.common.collect in tests 2021-04-14 15:47:48 -07:00
Stefan Spieker 364c8ac6fb fixed some deprecation warnings 2021-04-04 19:47:51 +02:00
James Nord c4e0291c50 [JENKINS-56934] fix the 'new view' link to correctly work with folders (#5377)
* [JENKINS-56934] fix the 'new view' link to correctly work with folders

* [JENKINS-56934] check permission on the correct item

* [JENKINS-56934] update and simplify the test

* [JENKINS-56934] check the owner is modifiable and refactor

* [JENKINS-56934] correct unit test, and add new test for non modifiable owner
2021-04-03 21:21:42 +02:00
Basil Crow 3f53051b0b Test cleanup (#5357) 2021-03-16 08:14:11 +00:00
Basil Crow 44c5342c58 Declare modifiers in JLS order (#5339) 2021-03-08 07:58:59 +00:00
Basil Crow 9cf3f73abd Clean up JUnit assertions (#5314) 2021-03-02 08:17:27 +00:00