提交 3b9a7c42 编写于 作者: P PJ Fanning

use of junit internal StringUtils is causing build issues

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1911518 13f79535-47bb-0310-9956-ffa450edef68
上级 8e40aabb
...@@ -42,7 +42,6 @@ import org.junit.jupiter.api.parallel.ExecutionMode; ...@@ -42,7 +42,6 @@ import org.junit.jupiter.api.parallel.ExecutionMode;
import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource; import org.junit.jupiter.params.provider.MethodSource;
import org.junit.platform.commons.util.StringUtils;
import org.opentest4j.AssertionFailedError; import org.opentest4j.AssertionFailedError;
/** /**
...@@ -262,7 +261,7 @@ public class TestAllFiles { ...@@ -262,7 +261,7 @@ public class TestAllFiles {
} }
} else { } else {
// verify that message is either null for both or set for both // verify that message is either null for both or set for both
assertTrue(actMsg != null || StringUtils.isBlank(exMessage), assertTrue(actMsg != null || isBlank(exMessage),
errPrefix + " for " + exClass + " expected message '" + exMessage + "' but had '" + actMsg + "'"); errPrefix + " for " + exClass + " expected message '" + exMessage + "' but had '" + actMsg + "'");
if (actMsg != null) { if (actMsg != null) {
...@@ -275,6 +274,16 @@ public class TestAllFiles { ...@@ -275,6 +274,16 @@ public class TestAllFiles {
} }
} }
private static boolean isBlank(final String str) {
final int strLen = str.length();
for (int i = 0; i < strLen; i++) {
if (!Character.isWhitespace(str.charAt(i))) {
return false;
}
}
return true;
}
private static String pathReplace(String msg) { private static String pathReplace(String msg) {
if (msg == null) return null; if (msg == null) return null;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册