need help - fail to run single test, although can run whole package (org.jetbrains.idea.maven)

So if i trying to run say org.jetbrains.idea.maven.compiler.ResourceCopyingTest it fails with NPE:
java.lang.NullPointerException
    at com.intellij.ide.plugins.IdeaPluginDescriptorImpl.insertDependency(IdeaPluginDescriptorImpl.java:497)
    at com.intellij.ide.plugins.PluginManager.initializePlugins(PluginManager.java:223)
    at com.intellij.ide.plugins.PluginManager.getPlugins(PluginManager.java:109)
    at com.intellij.openapi.application.impl.ApplicationImpl.loadApplicationComponents(ApplicationImpl.java:339)
    at com.intellij.openapi.application.impl.ApplicationImpl.<init>(ApplicationImpl.java:200)
    at com.intellij.openapi.application.ex.ApplicationManagerEx.createApplication(ApplicationManagerEx.java:36)
    at com.intellij.idea.CommandLineApplication.<init>(CommandLineApplication.java:58)
    at com.intellij.idea.CommandLineApplication.<init>(CommandLineApplication.java:52)
    at com.intellij.idea.IdeaTestApplication.<init>(IdeaTestApplication.java:33)
    at com.intellij.idea.IdeaTestApplication.getInstance(IdeaTestApplication.java:56)
    at com.intellij.testFramework.fixtures.impl.HeavyIdeaTestFixtureImpl.initApplication(HeavyIdeaTestFixtureImpl.java:169)
    at com.intellij.testFramework.fixtures.impl.HeavyIdeaTestFixtureImpl.setUp(HeavyIdeaTestFixtureImpl.java:90)
    at org.jetbrains.idea.maven.MavenTestCase.setUpFixtures(MavenTestCase.java:126)
    at org.jetbrains.idea.maven.MavenTestCase.setUp(MavenTestCase.java:82)
    at com.intellij.testFramework.UsefulTestCase.defaultRunBare(UsefulTestCase.java:228)
    at com.intellij.testFramework.UsefulTestCase$2.run(UsefulTestCase.java:238)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Did single test requires some specific setup? it's difficult to write a new test, because i just can't run it.

1 comment
Comment actions Permalink

Hello Alexander,

Add -Didea.platform.prefix=Idea to the list of VM options in the run configuration
for the tests.

So if i trying to run say
org.jetbrains.idea.maven.compiler.ResourceCopyingTest it fails with
NPE:
java.lang.NullPointerException
at
com.intellij.ide.plugins.IdeaPluginDescriptorImpl.insertDependency(Ide
aPluginDescriptorImpl.java:497)
at
com.intellij.ide.plugins.PluginManager.initializePlugins(PluginManager
.java:223)
at
com.intellij.ide.plugins.PluginManager.getPlugins(PluginManager.java:1
09)
at
com.intellij.openapi.application.impl.ApplicationImpl.loadApplicationC
omponents(ApplicationImpl.java:339)
at
com.intellij.openapi.application.impl.ApplicationImpl.<init>(Applicati
onImpl.java:200)
at
com.intellij.openapi.application.ex.ApplicationManagerEx.createApplica
tion(ApplicationManagerEx.java:36)
at
com.intellij.idea.CommandLineApplication.<init>(CommandLineApplication
.java:58)
at
com.intellij.idea.CommandLineApplication.<init>(CommandLineApplication
.java:52)
at
com.intellij.idea.IdeaTestApplication.<init>(IdeaTestApplication.java:
33)
at
com.intellij.idea.IdeaTestApplication.getInstance(IdeaTestApplication.
java:56)
at
com.intellij.testFramework.fixtures.impl.HeavyIdeaTestFixtureImpl.init
Application(HeavyIdeaTestFixtureImpl.java:169)
at
com.intellij.testFramework.fixtures.impl.HeavyIdeaTestFixtureImpl.setU
p(HeavyIdeaTestFixtureImpl.java:90)
at
org.jetbrains.idea.maven.MavenTestCase.setUpFixtures(MavenTestCase.jav
a:126)
at
org.jetbrains.idea.maven.MavenTestCase.setUp(MavenTestCase.java:82)
at
com.intellij.testFramework.UsefulTestCase.defaultRunBare(UsefulTestCas
e.java:228)
at
com.intellij.testFramework.UsefulTestCase$2.run(UsefulTestCase.java:23
8)
at
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThrea
d.java:269)
at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.j
ava:184)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThrea
d.java:174)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Did single test requires some specific setup? it's difficult to write
a new test, because i just can't run it.

---
Original message URL:
http://devnet.jetbrains.net/message/5281994#5281994


--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.