File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
integration-test/src/test/java/org/apache/iotdb/relational/it/query/recent/informationschema Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -207,15 +207,16 @@ private void testPrivilege() {
207207 }
208208 }
209209
210- @ Test
211- public void testMoreConfigurations () {
210+ private void testMoreConfigurations () {
212211 try {
213212 Connection connection =
214- EnvFactory .getEnv ().getConnection (ADMIN_NAME , ADMIN_PWD , BaseEnv .TABLE_SQL_DIALECT );
213+ EnvFactory .getEnv ().getConnection (ADMIN_NAME , ADMIN_PWD , BaseEnv .TABLE_SQL_DIALECT );
215214 Statement statement = connection .createStatement ();
216215 statement .execute ("USE information_schema" );
217216
218217 statement .execute ("set configuration \" query_cost_stat_window\" ='0'" );
218+ Thread .sleep (1_001 );
219+
219220 // query_cost_stat_window = 0, history queries are cleared
220221 String sql = "SELECT * FROM current_queries WHERE state='FINISHED'" ;
221222 ResultSet resultSet = statement .executeQuery (sql );
@@ -249,10 +250,12 @@ public void testMoreConfigurations() {
249250 try {
250251 statement .execute ("set configuration \" query_cost_stat_window\" ='10400000000'" );
251252 } catch (Exception e ) {
252- Assert .assertTrue (e .getMessage ().contains ("query_cost_stat_window" ));
253+ Assert .assertTrue (
254+ e .getMessage ()
255+ .contains ("java.lang.NumberFormatException: For input string: \" 10400000000\" " ));
253256 }
254- } catch (Exception e ) {
255- fail (e .getMessage (). concat ( "java.lang.NumberFormatException: For input string: \" 10400000000 \" " ) );
257+ } catch (Exception e ) {
258+ fail (e .getMessage ());
256259 }
257260 }
258261}
You can’t perform that action at this time.
0 commit comments