Any JUnit run/debug execution fails immediately with Error: could not open {argLine}
Answered
/scratch/jdk-9.0.1.jdk/Contents/Home/bin/java -ea @{argLine} -Xmx1024m -Dfile.encoding=UTF8 @{argLine} -Xmx1024m -Dfile.encoding=UTF8 [...]
Error: could not open `{argLine}'
This started happening suddenly, for no apparent reason. I re-opened the project, restart, and upgraded to the latest (see below), all with the same error.
Doesn't matter what test I try to run.
Version
IntelliJ IDEA 2017.3.4 (Ultimate Edition)
Build #IU-173.4548.28, built on January 29, 2018
Licensed to Oracle
JRE: 1.8.0_152-release-1024-b11 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Mac OS X 10.11.6
Please sign in to leave a comment.
I've also rebooted.
I also saw and tried the various "Shorten command line" options in the configurations. I had never seen this before, but am guessing that the issue I'm seeing is tied to this feature, and would appear to be a bug.
Found it. Someone had added this into a parent pom.xml, and while maven clearly understands how to deal with this, apparently IntelliJ doesn't:
Indeed such arguments are not parsed by IDE. Please vote and follow this issue: https://youtrack.jetbrains.com/issue/IDEA-143187