Commit 5fe7740
committed
Fix annotation of test-scope plugins with Java 9+
The build-time hack using EclipseHelper to index SciJava Common's
plugins was running only in conjunction with main class compilation,
not test class compilation. The reason SciJava Common's test classes
still got their plugins indexed is because there is an additional
invocation of EclipseHelper at runtime when tests are executed --
which works as long as the runtime class loader is a URLClassLoader.
But in Java 9+, the runtime class loader is not a URLClassLoader
anymore, so this late-stage runtime indexing of test-scoped plugins
does not occur. The result: when building with Java 9+, a bunch of
the tests were failing due to unindexed plugins in src/test/java.
The fix: run the EclipseHelper again during process-test-classes,
which is the proper phase for doing postprocessing to test classes.
This change lets Java 9+ compile SciJava Common with passing tests.1 parent 2c3ab68 commit 5fe7740
1 file changed
+11
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
223 | 223 | | |
224 | 224 | | |
225 | 225 | | |
| 226 | + | |
226 | 227 | | |
227 | 228 | | |
228 | 229 | | |
229 | 230 | | |
230 | 231 | | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
231 | 242 | | |
232 | 243 | | |
233 | 244 | | |
| |||
0 commit comments