Testing plugins (CMakeManager)

Andreas Pakulat apaku at gmx.de
Sun May 16 15:19:25 UTC 2010


On 16.05.10 08:50:56, Esben Mose Hansen wrote:
> is there a way to test plugins? I would need to be able to load the plugin 
> from a test, and the call various methods on it. 

Provide a test extension-interface. I don't like having plugin classes
exported from the module. The extension-header doesn't need any
exporting. See the IMakeBuilder extension interface. Similar to that you
could create a ITestCMakeManager that exposes the API you need and that
header shouldn't be installed. Then in the test query the plugin-manager
for the cmake-plugin (via its name) and call
extension<ITestCMakeManager>() on it.

Andreas

-- 
You should go home.




More information about the KDevelop-devel mailing list