title: Cannot resolve production code in tests after Android Studio Chipmunk automatically created modules
body: <p>I'm currently using Android Studio to develop a multi-module project by test-driven-development methods. It went well until I updated my IDE to Android Studio Chipmunk from previous Bumblebee.
  When I opened the project after the update, it seemed that AS automatically generated some modules for me. As you can see in the pic, those new names such as [main] and [unitTest] appeared in the project view automatically.
  <a href="https://i.stack.imgur.com/8qegV.png" rel="noreferrer">modules generated automatically</a></p>
  <p>After this, I found that the classes and methods of my production code could not be resolved in my test code. AS told me after I pressed Alt+Enter that I should add dependency to the main module of my production code. And it added one line in the build.gradle file: &quot;testImplementation project(path: ':app')&quot;. After syncing the gradle build, nothing had changed and it still could not resolve methods in my production code. I can still run the tests by executing gradle test tasks, but it is weird that I cannot use production code in my test code directly.</p>
  <p><strong>UPDATE:</strong></p>
  <p>For further information, I think this is a problem caused by the update from Intellij 2021.1 to 2021.2, since I re-installed AS Bumblebee and all seems worked fine. I also found this issue in JetBrains YouTrack that has an exactly same problem with me. Here is the link: <a href="https://youtrack.jetbrains.com/issue/IDEA-275566/Class-not-found-after-intellij-upgrade-2021-1-2-2021-2" rel="noreferrer">https://youtrack.jetbrains.com/issue/IDEA-275566/Class-not-found-after-intellij-upgrade-2021-1-2-2021-2</a></p>
  <p>This issue remains open and I've tried some other developers' reply in this issue to delete the .iml files, but the problem remains. I think Intellij 2021.1 and 2021.2 generate different .iml file in the .idea folder.</p>