listener leak in light project

This commit is contained in:
Alexey Kudravtsev
2011-01-31 15:23:16 +03:00
parent 34bd24decb
commit f21b99efe3
5 changed files with 24 additions and 12 deletions
@@ -193,7 +193,7 @@ public abstract class DaemonAnalyzerTestCase extends CodeInsightTestCase {
protected void tearDown() throws Exception {
((StartupManagerImpl)StartupManager.getInstance(getProject())).checkCleared();
if (toInitializeDaemon) {
((DaemonCodeAnalyzerImpl)DaemonCodeAnalyzer.getInstance(getProject())).projectClosed();
((DaemonCodeAnalyzerImpl)DaemonCodeAnalyzer.getInstance(getProject())).cleanupAfterTest(false);
}
super.tearDown();
((VirtualFilePointerManagerImpl)VirtualFilePointerManager.getInstance()).assertPointersDisposed();
@@ -48,9 +48,7 @@ public abstract class LightDaemonAnalyzerTestCase extends LightCodeInsightTestCa
@Override
protected void tearDown() throws Exception {
DaemonCodeAnalyzerImpl codeAnalyzer = (DaemonCodeAnalyzerImpl)DaemonCodeAnalyzer.getInstance(getProject());
codeAnalyzer.projectClosed();
((DaemonCodeAnalyzerImpl)DaemonCodeAnalyzer.getInstance(getProject())).cleanupAfterTest(true); // has to cleanup by hand since light project does not get disposed any time soon
super.tearDown();
}