'Intellij error - test framework quit unexpectedly intellij
I have been trying to run junit test but facing this issue constantly. I tried to look for answers on the internet but nothing helped.
]1
Solution 1:[1]
If there is an error e.g.
"
CommandLineWrapperis ill-suited for launching apps on Java 9+..."
Then, try the following workaround in IntelliJ IDEA:
Run -> Edit configurations -> select the failed running config -> Shorten command line: @argfile (Java 9+) -> OK
Solution 2:[2]
For IntelliJ 2019 and above go to :Settings-> Build,Execution,Deployment -> Build Tools -> Maven -> Running Tests and
Uncheck argLine
Solution 3:[3]
I had same issue but it has been resolved by updating the Intellij latest version 2020.3. Now i am able to run the test without any error. Please check below link for latest Intellij versions https://www.jetbrains.com/idea/download/
Solution 4:[4]
I had previously installed zulu and Oracle Java and then switched between the two quite a bit. I ended up having many JDKs
Here's what helped me.
In intelliJ, go to Run, the Edit Configurations. In the Run/Debug Configurations window, under Build and run section, select 'Java Bundled'.
To make sure this applies for all tests, click on the edit template icon (the spanner), select JUnit and then in the Build and run section select 'java Bundled'
Make sure all the configurations under JUnit has 'java Bundled' as well
Click Apply and Ok. Try to run the tests now and it should probably work.
Solution 5:[5]
For me the problem was that I had some incompatible/old dependencies in my SBT project.
I updated the versions of every 3rd party in the SBT config and running ZIO tests in IntelliJ started working.
Solution 6:[6]
For me also, the problem was that I made a change in the dependecies and the dependecy updated was incompatible in the SBT project.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | |
| Solution 2 | Benoy Prakash |
| Solution 3 | user3198259 |
| Solution 4 | mmmcho |
| Solution 5 | Peter Lamberg |
| Solution 6 | User42 |

