-
Notifications
You must be signed in to change notification settings - Fork 188
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
tycho-surefire-plugin:integration-test does not execute any test #643
Comments
By the way, I seem to understand that this feature is tested in https://github.com/eclipse/tycho/blob/e4e95b6b19a54a98ba3b0e9edbb1e8aeb3d9925b/tycho-its/src/test/java/org/eclipse/tycho/test/surefire/TestsInBundleTest.java but in that test the |
@LorenzoBettini thanks for looking into this it has been a while since I added this and it seems I removed some tests afterwards with commit 67dfb7f but I can't remember what was the issue it seems at least only one of them should have been removed. I'm still marking this as a regression even though it seems it never worked in any released version. |
@LorenzoBettini the problem is that somehow the surefireprocess gets confused with the classloading and thus the junit provider does not find the annotated classes :-\ I already tried to set the dependecy to the ones used in tycho but without success.
|
@laeubi so just reverting that commit does not fix things? |
This was just an experiment but don't work quite well as it relies on "additional.bundles" that has a different meaning in PDE. I think I know what the problem might be here but will need to take a deeper look at it tomorrow. |
The problem is that, if you don't rely on additional.bundles, the required bundles for testing will end up in the main code transitive dependencies, if I understand correctly... |
additional.bundles is inherently broken but as you said could be used for such purpose, but it is just a side-effect that it actually works. The correct way would be adding extra library entries with |
…ot execute any test - add delete integration tests back - generate a fragment to the host for additional imports Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
I thought that additional bundles was fixed a few releases ago. In particular, it now works as expected in Xtext |
We added support for a similar side-effect as in PDE in tycho yes...
Additional Bundles are meant for that you can add some bundles in advance and PDE adds import-package/require bundle when you run a product. I think that's not what xtext want nor how it is used, and I think not how one wan't tycho to behave. As a side-effect, this also adds the bundle and its dependencies to the classpath and as long as you only use it in test-code has a similar effect to a feature I requested for PDE here but was rejected (I implemented a POC here) and where I have now requested a slightly variant here now (but now response so far). So it may "work" under certain circumstances, but is still broken from my point of view. |
…ot execute any test - add integration tests back - generate a fragment to the host for additional imports - if given try to load the provider from the maven dependency classpath Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
…ot execute any test - add integration tests back - generate a fragment to the host for additional imports - if given try to load the provider from the maven dependency classpath Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
test - add integration tests back - generate a fragment to the host for additional imports - if given try to load the provider from the maven dependency classpath Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
I fixed the integration test + code, it should all work as desired now. |
@laeubi sorry for the delay: I seem to understand that:
in the log when |
I was trying the goal tycho-surefire-plugin:integration-test in an eclipse-plugin project, without any specific configuration, sticking to the default (*.IT.java), but when the goal runs in the integration-test phase no test is executed. I was trying that on a small project of mine, but I also tried the official example at
https://github.com/eclipse/tycho/tree/master/tycho-its/projects/surefire.combinedtests/bundle.test
I took the whole project and replaced a few values in the POM:
and
and ran
mvn verify
.This is (part of) the result:
So the JUnit tests with maven-surefire are correctly executed, but no JUnit test is executed by tycho-surefire
I also tried with Tycho 2.4.0 (when this feature was introduced by @laeubi ) but the problem is still there.
Using
-X
does not provide any further information.Am I missing something?
The text was updated successfully, but these errors were encountered: