@Test
	public void testClosedListener() {

		AtomicBoolean called = new AtomicBoolean();
		dialog.setClosedListener(() -> called.set(true));

		runSwing(() -> dialog.close());

		assertTrue("Dialog 'closed' listener not called", called.get());
	}
Interface for tests to signal what is expected of the executor
Ghidra/Features/Base/src/test.slow/java/ghidra/app/tablechooser/TableChooserDialogTest.java