Description
Version(s)
0.1.9
Describe the bug
After running scala-cli setup-ide .
for a project where tests & main sources are in the same root directory, the imported project structure is malformed (although workable).
This results in 2 bloop projects (1 for main scope and 1 for test scope). IntelliJ tries to import each as a separate module.
However, the resulting main scope module has no sources in it. It's an empty module.
Meanwhile, the test module contains sources from both scopes.
The root cause of this is IntelliJ's inability to have 2 modules with the same sources root. (IDEABKL-6745)
Expected behaviour
One of the following:
- only 1 module is created and contains sources for both scopes
- each module only contains sources from its relevant scope (currently unsupported by IntelliJ - IDEABKL-6745)
Known workaround
One can manually remove one of the imported modules - preferably the test one, and move the sources to the main one.
This bug doesn't technically break much, even without fixing it manually, everything can be compiled and run from IntelliJ out of the box. However, the malformed project still looks kind of bad, and may have some unforeseeable side effects for how the IDE works.