Community
Participate
Working Groups
If you run surefire in p2installed mode multiple times (with several mvn clean verify) on same application, it will fail because it tried to install a newer version of the bundle. The installation of units should also allow update, so the plugin could be run build and run multiple times on the same application, making it easier to develop tests.
I am right this only happens if you use an installation dir outside of the target/ folder? If so, I think the proper solution is to simply use a clean slate installation in the target/ folder. This would avoid accumulating state in between test runs in the first place (and it's the default for exactly that reason).
(In reply to Jan Sievers from comment #1) > I am right this only happens if you use an installation dir outside of the > target/ folder? Sorry, I didn't precise that. You're right, it's only when RCP app is pre-existing outside of target/ folder. > If so, I think the proper solution is to simply use a clean slate > installation in the target/ folder. This would avoid accumulating state in > between test runs in the first place (and it's the default for exactly that > reason). You're right, it can be a valid solution, however, I would feel good to have the provisining of surefire updating the bundle instead of just installing it. It wouldn't affect anything badly IMO. I'll try to come up with a patch later.
(In reply to comment #2) > You're right, it can be a valid solution, however, I would feel good to have the > provisining of surefire updating the bundle instead of just installing it. It > wouldn't affect anything badly IMO. > I'll try to come up with a patch later. Do you already have an idea how to approach this? Query the installation for what is installed? Or just issue an uninstall and ignore the exit code?
I have the feeling introspecting the target application to decide whether to update or not would be a cleaner approach. However, it appears to be more difficult to implement. So for now, I'm ok to stick with Jan's suggestion with a "prepare-test-application" step to copy/install application in target/ folder.
Eclipse Tycho is moving away from this bugs.eclipse.org issue tracker to https://github.com/eclipse/tycho/issues/ instead. If this issue is relevant to you, your action is required. 0. Verify this issue is still happening with latest Tycho 2.4.0-SNAPSHOT if issue has disappeared, please change status of this issue to "CLOSED WORKFORME" with some details about your testing environment and how you did verify the issue; and you're done if issue is still present when latest release: * Create a new issue at https://github.com/eclipse/tycho/issues/ ** Use as title in GitHub the title of this Bugzilla ticket (may include the bug number or not, at your own convenience) ** In the GitHub description, start with a link to this bugzilla ticket ** Optionally add new content to the description if it can helps towards resolution ** Submit GitHub issue * Update bugzilla ticket ** Add to "See also" property (up right column) the link to the newly created GitHub issue ** Add a comment "Migrated to <link-to-newly-created-GitHub-issue>" ** Set status as CLOSED MOVED ** Submit All issues that remain open will be automatically closed next week or so. Then the Bugzilla component for Tycho will be archived and made read-only.