argLine when running integration tests with Java 17

78 views
Skip to first unread message

Ullrich Hafner

unread,
Sep 19, 2022, 5:54:52 AM9/19/22
to JenkinsCI Developers
I recently switched my development to Java 17 and most things work flawlessly now.

One thing that I can’t get to work is debugging of integration tests in IntelliJ. It seems that the argLine command (that opens Java modules) is not sent to the debugging process.
However, the same tests run correctly when I am simply running the tests in IntelliJ (without debugger). Is there an additional option one can set in IntelliJ for the debugger? Or is this a bug in IntelliJ (I did not find something existing in their issue tracker)? I am using IntelliJ 2022.2.2 RC.

(I checked the option to pass the Arline to the run tests process)


Alex Earl

unread,
Sep 19, 2022, 10:32:43 AM9/19/22
to jenkin...@googlegroups.com
Hi Ullrich,

There is a known bug in IntelliJ, check out this post on Stackoverflow for the workaround.


Regards,

Alex

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/F4A29762-4EC8-471A-A8EA-626A677AB5C3%40gmail.com.


--

Ullrich Hafner

unread,
Sep 19, 2022, 2:35:22 PM9/19/22
to JenkinsCI Developers
I do not mean the bug that Basil explained in https://github.com/jenkinsci/plugin-pom/releases/tag/plugin-4.40
This has been fixed already in IntelliJ. 

IntelliJ now correctly runs the integration tests with an argLine like:
<argLine>-Djava.awt.headless=true -Xmx1024m -Djenkins.test.timeout=1000 --add-opens java.base/sun.reflect.annotation=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.util.concurrent=ALL-UNNAMED</argLine>
The problem is, that the argLine seems to be used for `Run With` only but not for `Debug With`.


Reply all
Reply to author
Forward
0 new messages