I created a plain old JAR with some fancy test classes I want to use to make testing more easy and fun.
Everybody knows Eclipse plug-ins aren't for unit testing and Tycho doesn't allow it, but we already managed a setup where we can test plug-ins using Surefire exactly the same way we test pure Maven projects. Using <pomDependencies>consider</pomDependencies>
in the config of the target-platform-configuration
allows for adding plain old Maven dependencies, so the Tycho build already works with the new fancy test classes.
Not Eclipse though. Plug-ins are missing the library "Maven Depdencies", and even adding it via the "Java Build Path" in the settings does nothing. I can add the project with the test classes there, but that would mean checking it from SVN and adding it to every workspace (I have 100, and I can't rule out that other people are working here, too).
On the other hand I can't just add it to the Manifest.MF because that would mean the test library would be shipped to our customers (which fancy or not is a bad idea). And I don't know how Tycho feels about optional dependencies, it's probably not a fan (and I feel like this would be bad style).
So how can I trick a plug-in in Eclipse into accepting a dependency that is not in the final plug-in?