-
Notifications
You must be signed in to change notification settings - Fork 320
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin test projects should not use "target/test-classes" in .classpath #2498
Comments
am not sure if this is coming from tycho, from tycho m2e or whatever. @ArneDeutsch do you remember why it is done as its currently done ( |
If I understand correctly from the generator, |
then we should fix that |
Currently, the Xtext wizard generates plugin test projects (e.g.,
.tests
and.ui.tests
) with source folders set as test source folders (correct!) but in the.classpath
the output folder is set astarget/test-classes
. I think this wrong, especially when such projects are build with Maven/Tycho (which is usually the case for plugin test projects): Tycho ignores such setting and always generates.class
files intotarget/classes
(NOTtarget/test-classes
). After all, plugin test projects are meant to contain only test code, so there's no risk of mixing main and test code (they'll be in different projects). Moreover, with the current settings in the.classpath
, Eclipse will generate.class
files (of tests) intarget/test-classes
while Tycho will generate it intarget/classes
. If you run the Maven/Tycho build from your Eclipse workspace you'll end up with duplicated.class
files for tests (intarget/classes
and intarget/test-classes
), leading to possible strange errors during tests (e.g., removed test cases are still executed, or removed test methods are still executed).I'd propose to generate
.classpath
files with outputtarget/classes
for plugin test projects.I can provide a PR.
The text was updated successfully, but these errors were encountered: