Skip to content

Commit

Permalink
Support -strict in test arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
niloc132 committed Nov 8, 2024
1 parent c2229e7 commit 7f6d6ba
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion user/build.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<project name="user" default="build" basedir=".">
<property name="gwt.root" location=".."/>
<property name="project.tail" value="user"/>
<property name="test.args" value="-ea -sourceLevel auto"/>
<property name="test.args" value="-ea -sourceLevel auto -strict"/>
<property name="test.jvmargs" value="-ea"/>

<!-- support old variables names -->
Expand Down
2 changes: 2 additions & 0 deletions user/src/com/google/gwt/junit/JUnitShell.java
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down Expand Up @@ -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 -----
Expand Down
2 changes: 1 addition & 1 deletion user/test/com/google/gwt/junit/JUnitShellTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -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) {
Expand Down

0 comments on commit 7f6d6ba

Please sign in to comment.