Skip to content

Commit ef73b4d

Browse files
committed
Enable extra warnings
1 parent fa1e48b commit ef73b4d

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

pom.xml

+4
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,10 @@
139139
<release>${java.minVersion}</release>
140140
<showDeprecation>true</showDeprecation>
141141
<showWarnings>true</showWarnings>
142+
<compilerArgs>
143+
<arg>-Xlint:all</arg>
144+
<arg>-Werror</arg>
145+
</compilerArgs>
142146
</configuration>
143147
</plugin>
144148
<plugin>

src/test/java/org/leplus/xslt/TestXSLT.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,9 @@ private void testXSLT(final File xsltFile, final File inputFile, final File expe
8686
throws TransformerException, SAXException, IOException {
8787
final File actualOutputFile = applyXSLT(inputFile, xsltFile);
8888
final String type = Files.probeContentType(actualOutputFile.toPath());
89-
if (type.startsWith(XML) || type.endsWith(XML)) {
89+
if (type != null && (type.startsWith(XML) || type.endsWith(XML))) {
9090
compareXML(expectedOutputFile, actualOutputFile);
91-
} else if (type.startsWith(JSON) || type.endsWith(JSON)) {
91+
} else if (type != null && (type.startsWith(JSON) || type.endsWith(JSON))) {
9292
compareJSON(expectedOutputFile, actualOutputFile);
9393
} else {
9494
compareFile(expectedOutputFile, actualOutputFile);

0 commit comments

Comments
 (0)