diff --git a/src/connector/jdbc/src/main/java/com/taosdata/jdbc/TSDBConnection.java b/src/connector/jdbc/src/main/java/com/taosdata/jdbc/TSDBConnection.java index 294544ed4742205f1aaae61a52f1a42c02bec030..f93412ffecb0673f946f187f13472a0b4d6a140e 100644 --- a/src/connector/jdbc/src/main/java/com/taosdata/jdbc/TSDBConnection.java +++ b/src/connector/jdbc/src/main/java/com/taosdata/jdbc/TSDBConnection.java @@ -197,7 +197,8 @@ public class TSDBConnection implements Connection { public SQLWarning getWarnings() throws SQLException { //todo: implement getWarnings according to the warning messages returned from TDengine - throw new SQLException(TSDBConstants.UNSUPPORT_METHOD_EXCEPTIONZ_MSG); + return null; +// throw new SQLException(TSDBConstants.UNSUPPORT_METHOD_EXCEPTIONZ_MSG); } public void clearWarnings() throws SQLException { diff --git a/tests/examples/JDBC/mybatisplus-demo/pom.xml b/tests/examples/JDBC/mybatisplus-demo/pom.xml index 8f5c04d4da6c4ca5a73ae873676d034e1666b5ed..e1bbcd9532cd408a6a5b781e1fe413cd469c4e7e 100644 --- a/tests/examples/JDBC/mybatisplus-demo/pom.xml +++ b/tests/examples/JDBC/mybatisplus-demo/pom.xml @@ -77,6 +77,20 @@ org.springframework.boot spring-boot-maven-plugin + + + org.apache.maven.plugins + maven-surefire-plugin + 2.17 + + + **/*Test.java + + + **/Abstract*.java + + + diff --git a/tests/examples/JDBC/mybatisplus-demo/src/main/resources/application-prod.yml b/tests/examples/JDBC/mybatisplus-demo/src/main/resources/application-prod.yml index ebc13736b2c11e90228a38b4e57f27738b617d13..9eb2ee66ebe8126db86b60905fcfdd32887b1356 100644 --- a/tests/examples/JDBC/mybatisplus-demo/src/main/resources/application-prod.yml +++ b/tests/examples/JDBC/mybatisplus-demo/src/main/resources/application-prod.yml @@ -3,7 +3,7 @@ spring: driver-class-name: com.taosdata.jdbc.TSDBDriver url: jdbc:TAOS://master:6030/mp_test user: root - password: 123456 + password: taosdata # driver-class-name: com.mysql.jdbc.Driver # url: jdbc:mysql://master:3306/test?useSSL=false diff --git a/tests/examples/JDBC/mybatisplus-demo/src/test/java/com/taosdata/example/mybatisplusdemo/mapper/WeatherMapperTest.java b/tests/examples/JDBC/mybatisplus-demo/src/test/java/com/taosdata/example/mybatisplusdemo/mapper/WeatherMapperTest.java index 7fc723a0b07a21c90067d7474e8241c5d119a87b..4354de883db72b9c36003337f92fe1f3834ba7d7 100644 --- a/tests/examples/JDBC/mybatisplus-demo/src/test/java/com/taosdata/example/mybatisplusdemo/mapper/WeatherMapperTest.java +++ b/tests/examples/JDBC/mybatisplus-demo/src/test/java/com/taosdata/example/mybatisplusdemo/mapper/WeatherMapperTest.java @@ -1,17 +1,16 @@ package com.taosdata.example.mybatisplusdemo.mapper; - import com.taosdata.example.mybatisplusdemo.domain.Weather; import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.context.junit4.SpringRunner; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; import java.util.List; -@RunWith(SpringRunner.class) +@RunWith(SpringJUnit4ClassRunner.class) @SpringBootTest public class WeatherMapperTest {