Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » How to test my plugin
How to test my plugin [message #591803] Wed, 11 February 2009 06:54
Mikael Petterson is currently offline Mikael PettersonFriend
Messages: 157
Registered: July 2009
Senior Member
Hi,

I am developing a plugin for Eclipse.
I try to write a simple testcase but it turned out it was not that simple.
This is the case.

public class ClearcaseProvider extends RepositoryProvider {
private final class RefreshStateOperation implements
IRecursiveOperation {

public IStatus visit(IResource resource, IProgressMonitor monitor)
{
StateCache cache =
StateCacheFactory.getInstance().get(resource);

}
}
}

Ok I thought since I cannot mock a singleton I can check if I really need
a singleton and make the coupling more lose. So I thought I could send an
instance of StateCacheFacotry into the constructor of ClearcaseProvider
class to make the two classes less tightly coupled. This is not possible
since that constructor will never be called from the Eclipse framework.

Any hints or pointers so I can test the plugin is very much appreciated.

//mikael
Previous Topic:PDE Build, P2 metadata: Category setup, site.xml
Next Topic:headless build - avoid jaring of a plugin being available as directory
Goto Forum:
  


Current Time: Sun Jul 25 11:25:33 GMT 2021

Powered by FUDForum. Page generated in 0.01757 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top