Similar error as https://devnet.jetbrains.com/message/5494790 but different goal.
I'm trying to write a test for my project import wizard using ProjectWizardTestCase. If I use the importProjectFrom method I get a bunch of "Not disposed pointer" errors but the test still passes (ideally, I'd like to get rid of those, too). The problem with that method is I'd like to get all modules which were created as a result of the import, but it only gives you one of the modules. I can hack around it by getting that one module, getting its project, then looking up that project's modules, and potentially diffing those against ones that existed prior, but that seems, well, like a hack.
So I basically copy-pasted the importFrom method and instead of returning just the first module I return all of them. Unfortunately, this gives me the "Listeners leaked for interface", along with those "Not disposed pointer" errors. I guess I'm not cleaning up properly, but it's not clear how to do so.
You can see the failing build here - https://travis-ci.org/carymrobbins/intellij-haskforce/jobs/82886876#L303
And the problematic test case here - https://github.com/carymrobbins/intellij-haskforce/blob/aa6c9f7c32633b33622d99cd48d0a8147ee18dd2/tests/com/haskforce/importWizard/stack/StackImportWizardTest.scala#L47-L62
And, for completeness, the hacky workaround using only the first module, which works - https://github.com/carymrobbins/intellij-haskforce/blob/aa6c9f7c32633b33622d99cd48d0a8147ee18dd2/tests/com/haskforce/importWizard/stack/StackImportWizardTest.scala#L30-L45
For what it's worth, I've also implemented (semantically) the same tests in Java (since these are in Scala) and have gotten the same errors.