packages - Something strange with Project Paths in IntelliJ 14.1.4 -
so, has started act weird in intellij project. tried removing iml , .idea data, no avail.
i go project structure. there, have content root. withing, have 3 folders - 1 jar (and jni lib), 1 samples , 1 tools (just tools written use jar). jar, samples , tools marked blue (sources).
in jar folder, have source tree (com\company\projectname\xxx), lib folder, folder jni lib , folder created call 'junit', focus of question. marked in project structure in green (tests).
within, have folder structure eerily similar code: com\company\projectname\junit.
when open file in junit\com\company\xxx\junit, have big red underline under package com.company.xxx.junit; line tells me: "package name 'com.company.xxx.junit' not correspond file path 'junit.com.company.xxx.junit'.
i under impression marking folder 'tests' instruct ide use "parent" folder, if will, eliminating need prepend folder name.
how can separate code unit tests , in fact, create 2 junit test suites (one internal use, other 'skeleton' distribution), park them under 1 "umbrella" folder , not have prepend package names folder name?
update: project structure:
based on screen shot, issue junit directory subdirectory of source directory, namely myprovider. source directory (whether "production" source or unit test source directory) cannot subdirectory of source directory.
you need either:
- move
junitdirectory out ofmyprovidersibling directory, or - unmark
myprovidersource directory, createmain(or such directory) inmyprovider, mark source directory, , movecomdirectory/packagemain.
option 2 preferred way deal follows common directory structure standard.
update (following comment op)



Comments
Post a Comment