From 7f6d6ba409e9bcf3f47fdd265c756d08a45a96f6 Mon Sep 17 00:00:00 2001 From: Colin Alworth Date: Thu, 7 Nov 2024 21:24:57 -0600 Subject: [PATCH 1/2] Support -strict in test arguments Fixes #10037 --- user/build.xml | 2 +- user/src/com/google/gwt/junit/JUnitShell.java | 2 ++ user/test/com/google/gwt/junit/JUnitShellTest.java | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/user/build.xml b/user/build.xml index 2af156012ff..4e70cf0f39c 100755 --- a/user/build.xml +++ b/user/build.xml @@ -1,7 +1,7 @@ - + diff --git a/user/src/com/google/gwt/junit/JUnitShell.java b/user/src/com/google/gwt/junit/JUnitShell.java index 53f67a7cb2f..842c1ad9794 100644 --- a/user/src/com/google/gwt/junit/JUnitShell.java +++ b/user/src/com/google/gwt/junit/JUnitShell.java @@ -60,6 +60,7 @@ import com.google.gwt.dev.util.arg.ArgHandlerScriptStyle; import com.google.gwt.dev.util.arg.ArgHandlerSetProperties; import com.google.gwt.dev.util.arg.ArgHandlerSourceLevel; +import com.google.gwt.dev.util.arg.ArgHandlerStrict; import com.google.gwt.dev.util.arg.ArgHandlerWarDir; import com.google.gwt.dev.util.arg.ArgHandlerWorkDirOptional; import com.google.gwt.junit.JUnitMessageQueue.ClientStatus; @@ -299,6 +300,7 @@ public int handle(String[] args, int tagIndex) { registerHandler(new ArgHandlerFilterJsInteropExports(options)); registerHandler(new ArgHandlerSetProperties(options)); registerHandler(new ArgHandlerClosureFormattedOutput(options)); + registerHandler(new ArgHandlerStrict(options)); /* * ----- Options specific to JUnitShell ----- diff --git a/user/test/com/google/gwt/junit/JUnitShellTest.java b/user/test/com/google/gwt/junit/JUnitShellTest.java index e5b8534d6e0..19695aaa89f 100644 --- a/user/test/com/google/gwt/junit/JUnitShellTest.java +++ b/user/test/com/google/gwt/junit/JUnitShellTest.java @@ -45,7 +45,7 @@ public void testDefaultModuleUrl() throws Exception { public void testArgOptimize() throws Exception { parseGoodArgs("-optimize", "8", "-XdisableInlineLiteralParameters", "-XdisableRemoveDuplicateFunctions", "-XdisableClusterSimilarFunctions", - "-XdisableOrdinalizeEnums", "-XdisableOptimizeDataflow"); + "-XdisableOrdinalizeEnums", "-XdisableOptimizeDataflow", "-strict"); } private void parseGoodArgs(String... argsToUse) { From fd7f88dad185a8192016126a2947f11a9e0bd804 Mon Sep 17 00:00:00 2001 From: Colin Alworth Date: Fri, 8 Nov 2024 08:27:27 -0600 Subject: [PATCH 2/2] Revert adding -strict to all user tests See #10038 --- user/build.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user/build.xml b/user/build.xml index 4e70cf0f39c..2af156012ff 100755 --- a/user/build.xml +++ b/user/build.xml @@ -1,7 +1,7 @@ - +