fix for: show project leaking path in tests Alexey Kudravtsev 23.03.2017 14:41

This commit is contained in:
Alexey Utkin
2017-03-23 20:00:17 +03:00
parent d4b1163771
commit b12aa86b50
@@ -389,11 +389,11 @@ public abstract class PlatformTestCase extends UsefulTestCase implements DataPro
}
public static void cleanupApplicationCaches(Project project) {
UndoManagerImpl globalInstance = (UndoManagerImpl)UndoManager.getGlobalInstance();
if (globalInstance != null) {
globalInstance.dropHistoryInTests();
}
if (project != null && !project.isDisposed()) {
UndoManagerImpl globalInstance = (UndoManagerImpl)UndoManager.getGlobalInstance();
if (globalInstance != null) {
globalInstance.dropHistoryInTests();
}
((UndoManagerImpl)UndoManager.getInstance(project)).dropHistoryInTests();
((DocumentReferenceManagerImpl)DocumentReferenceManager.getInstance()).cleanupForNextTest();