forked from plusone/plusone-commons
Merge branch 'dev' of http://zhouxy.xyz:3000/ZhouXY108/plusone-commons into dev
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
package xyz.zhouxy.plusone.commons.function;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||
|
||||
import java.util.Objects;
|
||||
import java.util.function.Predicate;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import xyz.zhouxy.plusone.commons.util.Assert;
|
||||
|
||||
class FunctionTests {
|
||||
|
||||
@@ -14,6 +15,6 @@ class FunctionTests {
|
||||
String str = "";
|
||||
Predicate<String> predicate = Predicates.<String>of(Objects::nonNull)
|
||||
.and(StringUtils::isNotBlank);
|
||||
Assert.isFalse(predicate.test(str), "校验应是不通过");
|
||||
assertFalse(predicate.test(str), "校验应是不通过");
|
||||
}
|
||||
}
|
||||
|
@@ -3,6 +3,7 @@ package xyz.zhouxy.plusone.commons.util;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||
import static xyz.zhouxy.plusone.commons.jdbc.JdbcSql.IN;
|
||||
import static xyz.zhouxy.plusone.commons.jdbc.SimpleJdbcTemplate.ParamBuilder.*;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.SQLException;
|
||||
@@ -49,7 +50,7 @@ class SimpleJdbcTemplateTests {
|
||||
@Test
|
||||
void testQuery() throws SQLException {
|
||||
try (Connection conn = this.dataSource.getConnection()) {
|
||||
Object[] params = SimpleJdbcTemplate.buildParams("501533", "501554", "544599");
|
||||
Object[] params = buildParams("501533", "501554", "544599");
|
||||
String sql = SQL.newJdbcSql()
|
||||
.SELECT("*")
|
||||
.FROM("test_table")
|
||||
|
Reference in New Issue
Block a user