From ded7b0af8f215075e586a128a13caafba2aeb015 Mon Sep 17 00:00:00 2001 From: opokharel Date: Sat, 25 Jun 2022 11:35:39 -0600 Subject: [PATCH] BAEL-5421 --- .../java/com/baeldung/jar/MySampleGUIAppnUnitTest.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/core-java-modules/core-java-jar/src/test/java/com/baeldung/jar/MySampleGUIAppnUnitTest.java b/core-java-modules/core-java-jar/src/test/java/com/baeldung/jar/MySampleGUIAppnUnitTest.java index f13b55158c..28bb7cc7a8 100644 --- a/core-java-modules/core-java-jar/src/test/java/com/baeldung/jar/MySampleGUIAppnUnitTest.java +++ b/core-java-modules/core-java-jar/src/test/java/com/baeldung/jar/MySampleGUIAppnUnitTest.java @@ -1,14 +1,16 @@ package com.baeldung.jar; +import java.io.IOException; + import org.junit.jupiter.api.Test; -class MySampleGUIAppnUnitTest throws IOException { +class MySampleGUIAppnUnitTest { @Test void testMain() throws IOException { MySampleGUIAppn instance = new MySampleGUIAppn(); String [] args = null; - System.exit(DO_NOTHING_ON_CLOSE); - main(args); + System.exit(0); + MySampleGUIAppn.main(args); } } \ No newline at end of file