@BeforeTest(alwaysRun = true)
public static void clearDesktop()
{
- if (Desktop.instance != null && Desktop.getAlignFrames() != null)
+ if (Desktop.instance != null && Desktop.getFrames() != null
+ && Desktop.getFrames().length > 0)
{
Desktop.instance.closeAll_actionPerformed(null);
}