From 87b92e9a4667d8d86da8742595ed141c7cf19d20 Mon Sep 17 00:00:00 2001 From: Dennis Zhuang Date: Fri, 29 Dec 2023 17:05:01 +0800 Subject: [PATCH] fix: instance test --- tests-integration/src/tests/instance_test.rs | 76 +++++++++++--------- 1 file changed, 42 insertions(+), 34 deletions(-) diff --git a/tests-integration/src/tests/instance_test.rs b/tests-integration/src/tests/instance_test.rs index 4ec29090e607..686b98a2ee1c 100644 --- a/tests-integration/src/tests/instance_test.rs +++ b/tests-integration/src/tests/instance_test.rs @@ -1775,45 +1775,53 @@ async fn test_information_schema_dot_columns(instance: Arc) { let output = execute_sql(&instance, sql).await; let expected = "\ -+---------------+--------------------+------------+---------------+-----------+---------------+ -| table_catalog | table_schema | table_name | column_name | data_type | semantic_type | -+---------------+--------------------+------------+---------------+-----------+---------------+ -| greptime | information_schema | columns | table_catalog | String | FIELD | -| greptime | information_schema | columns | table_schema | String | FIELD | -| greptime | information_schema | columns | table_name | String | FIELD | -| greptime | information_schema | columns | column_name | String | FIELD | -| greptime | information_schema | columns | data_type | String | FIELD | -| greptime | information_schema | columns | semantic_type | String | FIELD | -| greptime | public | numbers | number | UInt32 | TAG | -| greptime | information_schema | tables | table_catalog | String | FIELD | -| greptime | information_schema | tables | table_schema | String | FIELD | -| greptime | information_schema | tables | table_name | String | FIELD | -| greptime | information_schema | tables | table_type | String | FIELD | -| greptime | information_schema | tables | table_id | UInt32 | FIELD | -| greptime | information_schema | tables | engine | String | FIELD | -+---------------+--------------------+------------+---------------+-----------+---------------+"; ++---------------+--------------------+------------+----------------+-----------+---------------+ +| table_catalog | table_schema | table_name | column_name | data_type | semantic_type | ++---------------+--------------------+------------+----------------+-----------+---------------+ +| greptime | information_schema | columns | table_catalog | String | FIELD | +| greptime | information_schema | columns | table_schema | String | FIELD | +| greptime | information_schema | columns | table_name | String | FIELD | +| greptime | information_schema | columns | column_name | String | FIELD | +| greptime | information_schema | columns | data_type | String | FIELD | +| greptime | information_schema | columns | semantic_type | String | FIELD | +| greptime | information_schema | columns | column_default | String | FIELD | +| greptime | information_schema | columns | is_nullable | String | FIELD | +| greptime | information_schema | columns | column_type | String | FIELD | +| greptime | information_schema | columns | column_comment | String | FIELD | +| greptime | public | numbers | number | UInt32 | TAG | +| greptime | information_schema | tables | table_catalog | String | FIELD | +| greptime | information_schema | tables | table_schema | String | FIELD | +| greptime | information_schema | tables | table_name | String | FIELD | +| greptime | information_schema | tables | table_type | String | FIELD | +| greptime | information_schema | tables | table_id | UInt32 | FIELD | +| greptime | information_schema | tables | engine | String | FIELD | ++---------------+--------------------+------------+----------------+-----------+---------------+"; check_output_stream(output, expected).await; let output = execute_sql_with(&instance, sql, query_ctx).await; let expected = "\ -+-----------------+--------------------+---------------+---------------+----------------------+---------------+ -| table_catalog | table_schema | table_name | column_name | data_type | semantic_type | -+-----------------+--------------------+---------------+---------------+----------------------+---------------+ -| another_catalog | another_schema | another_table | i | TimestampMillisecond | TIMESTAMP | -| another_catalog | information_schema | columns | table_catalog | String | FIELD | -| another_catalog | information_schema | columns | table_schema | String | FIELD | -| another_catalog | information_schema | columns | table_name | String | FIELD | -| another_catalog | information_schema | columns | column_name | String | FIELD | -| another_catalog | information_schema | columns | data_type | String | FIELD | -| another_catalog | information_schema | columns | semantic_type | String | FIELD | -| another_catalog | information_schema | tables | table_catalog | String | FIELD | -| another_catalog | information_schema | tables | table_schema | String | FIELD | -| another_catalog | information_schema | tables | table_name | String | FIELD | -| another_catalog | information_schema | tables | table_type | String | FIELD | -| another_catalog | information_schema | tables | table_id | UInt32 | FIELD | -| another_catalog | information_schema | tables | engine | String | FIELD | -+-----------------+--------------------+---------------+---------------+----------------------+---------------+"; ++-----------------+--------------------+---------------+----------------+----------------------+---------------+ +| table_catalog | table_schema | table_name | column_name | data_type | semantic_type | ++-----------------+--------------------+---------------+----------------+----------------------+---------------+ +| another_catalog | another_schema | another_table | i | TimestampMillisecond | TIMESTAMP | +| another_catalog | information_schema | columns | table_catalog | String | FIELD | +| another_catalog | information_schema | columns | table_schema | String | FIELD | +| another_catalog | information_schema | columns | table_name | String | FIELD | +| another_catalog | information_schema | columns | column_name | String | FIELD | +| another_catalog | information_schema | columns | data_type | String | FIELD | +| another_catalog | information_schema | columns | semantic_type | String | FIELD | +| another_catalog | information_schema | columns | column_default | String | FIELD | +| another_catalog | information_schema | columns | is_nullable | String | FIELD | +| another_catalog | information_schema | columns | column_type | String | FIELD | +| another_catalog | information_schema | columns | column_comment | String | FIELD | +| another_catalog | information_schema | tables | table_catalog | String | FIELD | +| another_catalog | information_schema | tables | table_schema | String | FIELD | +| another_catalog | information_schema | tables | table_name | String | FIELD | +| another_catalog | information_schema | tables | table_type | String | FIELD | +| another_catalog | information_schema | tables | table_id | UInt32 | FIELD | +| another_catalog | information_schema | tables | engine | String | FIELD | ++-----------------+--------------------+---------------+----------------+----------------------+---------------+"; check_output_stream(output, expected).await; }