Mehraj Malik
Mehraj Malik

Reputation: 15874

IntelliJ showing source and test files in same package

I am using IntelliJ 2011.1.1 CE and now suddenly it start showing source (.java) and test classed in same package. I have selected "packages" view which is used to show only src files

Screenshot

Upvotes: 1

Views: 618

Answers (1)

Andrey
Andrey

Reputation: 16431

Packages view has always shown both test and production classes.

If test and production files are located in different modules you can enable Show Modules option to separate them: enter image description here

It also shows test files with different background colors, which you can configure in Settings (Preferences on macOS) | Appearance & Behavior | File Colors | Appearance & Behavior | File Colors.

A related request: IDEA-144965 Add option to hide test files in the 'Packages' of 'Project' tool window

Upvotes: 0

Related Questions