title: IntelliJ: Source root is not handled correctly
body: <p>I have the following project structure:</p>
  
  <pre><code>ModuleName (=Content Root)
    |---src
    |    |---com
    |         |---company
    |             |---file1.java
    |             |---file2.java
    |---test-src
    |    |---com
    |         |---company
    |             |---test.java
    |--- .classpath
    |--- .project
  </code></pre>
  
  <p>This was an Eclipse project initially, and I need to import it in IntelliJ.</p>
  
  <p>However, everytime I try to import it, IntelliJ is completely confused with the source root folder.</p>
  
  <p>Looking at the java source files, I get the following error in the package declaration:</p>
  
  <pre><code>package com.company;
  </code></pre>
  
  <blockquote>
    <p>Error: Package name 'com.company' does not correspond to the file path 'src/com.company'</p>
  </blockquote>
  
  <p>and</p>
  
  <blockquote>
    <p>Error: Package name 'com.company' does not correspond to the file path 'test-src/com.company'</p>
  </blockquote>
  
  <p>I correctly marked the 'src' and 'test-src' folders as source-roots in IntelliJ. However, it always thinks that these folders are part of the package hierarchy.</p>
  
  <p>I have this problem in 3 of about 30 different modules. All modules are structured the same, and I don't really see any reason why IntelliJ works for most of them, but fails for those three.</p>
  
  <p>How can I resolve this?</p>