Skip to content

Commit 17da11c

Browse files
committed
fix: closing terminal view after tests
1 parent de52bb4 commit 17da11c

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

tests/com.espressif.idf.ui.test/src/com/espressif/idf/ui/test/TerminalViewTest.java

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
1616
import org.eclipse.swtbot.swt.finder.widgets.SWTBotCanvas;
1717
import org.eclipse.swtbot.swt.finder.widgets.SWTBotToolbarButton;
18+
import org.junit.AfterClass;
1819
import org.junit.BeforeClass;
1920
import org.junit.Test;
2021
import org.junit.runner.RunWith;
@@ -35,6 +36,20 @@ public static void setup() throws Exception
3536
EnvSetupOperations.setupEspressifEnv(bot);
3637
}
3738

39+
@AfterClass
40+
public static void cleanup() throws Exception
41+
{
42+
try
43+
{
44+
SWTBotView terminalView = bot.viewByTitle("Terminal");
45+
terminalView.close();
46+
}
47+
catch (WidgetNotFoundException ignored)
48+
{
49+
}
50+
51+
}
52+
3853
@Test
3954
public void testOpenTerminalView() throws Exception
4055
{

0 commit comments

Comments
 (0)