Skip to content
Snippets Groups Projects
Commit ec938f1e authored by Jan Gruteser's avatar Jan Gruteser
Browse files

readd resetGlobals for tests

otherwise some required trace files are not created
parent d0a2425a
No related branches found
No related tags found
No related merge requests found
Pipeline #143640 passed
...@@ -209,6 +209,8 @@ public class TLC4B { ...@@ -209,6 +209,8 @@ public class TLC4B {
public static void test(String[] args, boolean deleteFiles) throws Exception { public static void test(String[] args, boolean deleteFiles) throws Exception {
System.setProperty("apple.awt.UIElement", "true"); // avoiding pop up windows System.setProperty("apple.awt.UIElement", "true"); // avoiding pop up windows
TLC4BGlobals.resetGlobals();
TLC4BGlobals.setDeleteOnExit(deleteFiles);
TLC4B tlc4b = new TLC4B(); TLC4B tlc4b = new TLC4B();
try { try {
tlc4b.process(args); tlc4b.process(args);
...@@ -217,7 +219,6 @@ public class TLC4B { ...@@ -217,7 +219,6 @@ public class TLC4B {
printlnErr(e.getMessage()); printlnErr(e.getMessage());
throw e; throw e;
} }
TLC4BGlobals.setDeleteOnExit(deleteFiles);
if (TLC4BGlobals.isRunTLC()) { if (TLC4BGlobals.isRunTLC()) {
MP.TLCOutputStream.changeOutputStream(); MP.TLCOutputStream.changeOutputStream();
TLCRunner.runTLC(tlc4b.machineFileNameWithoutFileExtension, tlc4b.buildDir); TLCRunner.runTLC(tlc4b.machineFileNameWithoutFileExtension, tlc4b.buildDir);
...@@ -233,6 +234,7 @@ public class TLC4B { ...@@ -233,6 +234,7 @@ public class TLC4B {
public static void testString(String machineString, boolean deleteFiles) throws Exception { public static void testString(String machineString, boolean deleteFiles) throws Exception {
System.setProperty("apple.awt.UIElement", "true"); // avoiding pop up windows System.setProperty("apple.awt.UIElement", "true"); // avoiding pop up windows
TLC4BGlobals.resetGlobals();
TLC4BGlobals.setDeleteOnExit(deleteFiles); TLC4BGlobals.setDeleteOnExit(deleteFiles);
TLC4B tlc4b = new TLC4B(); TLC4B tlc4b = new TLC4B();
tlc4b.buildDir = new File("temp/"); tlc4b.buildDir = new File("temp/");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment