Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Running JUnit tests that use a debugging workspace

Hello All,

I am trying to write a JUnit test that needs to use a workspace. I noticed
that the tests under the org.eclipse.cdt.core.model.tests package do this in
setup(). I tried to run these tests through the JUnit Launch Configuration,
but all fail when trying to get the workspace: 
        workspace= ResourcesPlugin.getWorkspace();
        root= workspace.getRoot();
Null pointer exception (workspace = null)!
So what is the proper way for running these tests? Is there anything special
to do to setup a debugging workspace?

Appreciate your help,
Hoda



Back to the top