Don't use Thread.sleep in Swing; since Swing (like all GUI frameworks) is not
thread safe, everything has to run on the one thread. If you sleep that thread you can make the entire GUI unresponsive. You can read more about threads
here.
Why have you got a static field in the Test class? If you don't have a good reason for it, using the keyword static is a mistake.
Don't use null Layout. Always use a concrete layout, as in the
Java Tutorials, MigLayout, etc.
I shall move this discussion to our GUIs forum.