Cannot 'run all tests...' anymore

Answered

Hi,

I have been frequently running all the tests in a package/directory by right clicking the directory or module and selecting 'Run all tests'. At some point though this has stopped working - intellij simply reports '0 test class found in package...'.
Its something thats happened to this one project. If I create a new maven module in the same project, I'll have the same problem - but if I create a new project and add a new maven module, it works.

If I run 'mvn install' my tests run fine.

Anyone have any suggestions how I debug and fix this?

Thanks.

0
9 comments

Hello Paul,

Please try to invalidate caches (https://www.jetbrains.com/idea/webhelp/cleaning-system-cache.html) and reimport your project. If it doesn't help please attach idea.log ("Help - Show Log in...") after reproducing the issue.

0
Avatar
Permanently deleted user

Thanks, invalidating caches and restarting was the first thing I tried - it didn't help.
I have created a new project and imported the same modules and it was working okay until I modified my run config - I removed 'make' and add a 'maven install' to try something out. After I did that, I could never (from any run config) get it to find tests. I removed the maven target and put 'make' back in but it didn't help. Creating a new project was the only thing I could find that would help.

I will try this again on a trivial maven project and post the log.

Thanks.

0
Avatar
Permanently deleted user

Hi,

I've tried this on a trivial maven project in IDEA 13.1.2 on MacOs and so far I haven't been able to reproduce the problem.

I think it must be something to do with the way the project poms are set up - there's all sorts of customisations around the testing and a chain of parent poms so I'll dig through that.
I'm not convinced its a problem with Intellij.

Are the run configurations influenced at all by the maven pom configuration?

Thanks.

0
Avatar
Yaroslav Bedrov

Paul,

I'll need idea.log to investigate the issue. Also it would be great if you could attach sample project describing the problem.

0

Had the same issue with my project. Fixed by removing .idea package from the project and open it as a new one from existing source

0

Invalidating Caches solved the problem for a few seconds, and than the menu-entries disappeard again. Running IntelliJ IDEA 2025.3.1.1

0

Hi Tonino Ferrara, Thank you for your feedback.

I could not reproduce the issue on my side using IntelliJ IDEA 2025.3.1.1. 
Could you please try to perform the following steps to resolve this problem:

  1. Close your project (File → Close Project);
  2. Close all instances of IntelliJ IDEA;
  3. Rename or remove the System Directory;
  4. Run IDEA and re-import the Project: Open → Navigate to the Project's directory → Double-click the root pom.xml → Open as Project

After that check if it works correctly. If not, please collect IDE logs via Help | Collect Logs and Diagnostic Data after reproducing this issue and upload them to our server https://uploads.jetbrains.com/ and provide us with the Upload ID. The uploaded data will be accessible only to our team and will be used solely for investigating this issue. Thank you!

0

I deleted the System Directory, but that did not help. I uploaded the requested files: 2026_01_12_G5W38YcTUW98q8H3pAP8zx

0

Tonino Ferrara, thank you!
Unfortunately, the idea.log file from the provided logs is empty.
Could you please reproduce this issue again and then collect IDE logs via Help | Collect Logs and Diagnostic Data?
After that please create a new ticket using this link and provide new Upload ID to log files there. We will investigate your report individually.

We appreciate your understanding!

0

Please sign in to leave a comment.