fix(iotdb): omit tree database from session handshake

Closes #5826
This commit is contained in:
t8y2 committed 2026-08-12 15:45:24 +00:00
1 parent 9fb70bcfc9
commit 847afca6fe
2 files changed
+27 -6

No files matched your search

+24
View File
@@ -87,6 +87,30 @@ func TestLiveIoTDBAgentTreeAndTable(t *testing.T) {
}
}
func TestLiveIoTDBAgentTreeDatabaseConnection(t *testing.T) {
if os.Getenv("DBX_IOTDB_LIVE") != "1" {
t.Skip("set DBX_IOTDB_LIVE=1 to run against a real IoTDB server")
}
database := "root.dbx_go_connection_" + strconv.Itoa(os.Getpid())
bootstrap := liveIoTDBServer(t, connectParams{})
defer bootstrap.disconnect()
mustExecuteNonQuery(t, bootstrap, "CREATE DATABASE "+database, "")
defer func() { _ = bootstrap.executeNonQuery("DELETE DATABASE "+database, "", 0) }()
scoped := liveIoTDBServer(t, connectParams{Database: database})
defer scoped.disconnect()
if err := scoped.validateConnection(); err != nil {
t.Fatal(err)
}
tables, err := scoped.listTables(database, metadataListConstraints{})
if err != nil {
t.Fatal(err)
}
if tables == nil {
t.Fatal("expected an initialized tree table list")
}
}
func TestLiveIoTDBAgentProcessMultiSessionAndCancellation(t *testing.T) {
if os.Getenv("DBX_IOTDB_LIVE") != "1" {
t.Skip("set DBX_IOTDB_LIVE=1 to run against a real IoTDB server")