Or is my whole idea of running entire tests in the EDT doomed from the start
When it comes to modal dialogs, yes.
How do I assert on Swing modal dialogs?
Upon asynchronously calling a blocking showing method (e.g. with SwingUtilities.invokeLater()
), you waitForIdle()
outside of the EDT and then assert.
All creations, mutations, access of Swing components, on the other hand, should be done in the EDT. See this answer for an example.