Junit 5 @ParametrizedTest is not recognized as test method

44 views
Skip to first unread message

marc.b...@davidson.fr

unread,
Apr 12, 2018, 4:36:38 AM4/12/18
to SonarLint
Hello,

I am using SonarLint in IntelliJ Idea.
IntelliJ Idea version : Ultimate 2018.1.
SonarLint version: 3.0.0.2041

I just migrated a small java project to Junit 5 with experimental parametrized tests feature.

I get a critical issue in a test class with only one @ParametrizedTest

Rule : TestCases should contain tests
Message : Add some tests to this class



janos....@sonarsource.com

unread,
Apr 16, 2018, 3:12:11 AM4/16/18
to SonarLint
Hi,

SonarLint for IntelliJ 3.0.0 is very old. If you are using it in standalone mode, then the Java analyzer embedded in it is also old. Support for Junit5 was added in newer versions of the analyzer. In the latest version of SonarLint for IntelliJ (3.3) with the embedded Java analyzer (5.1.1), the issue you describe should not happen.

Cheers,
Janos

marc.b...@davidson.fr

unread,
Apr 16, 2018, 6:29:09 AM4/16/18
to SonarLint
I was stuck on 3.0.0 version without knowing it. After uninstallnig and reinstalling the plugin at the latest version. It is indeed fixed.

Thanks for your answer.
Reply all
Reply to author
Forward
0 new messages