Skip to content
Snippets Groups Projects
Commit b385c8c3 authored by Вартан Бабаян's avatar Вартан Бабаян :dart:
Browse files

test: create table with tier syntax

parent 7c708e63
No related branches found
No related tags found
1 merge request!1414sbroad import
......@@ -3790,7 +3790,30 @@ fn front_mock_set_param_transaction() {
}
}
// TODO: add test for create table in tier syntax
#[test]
fn front_create_table_with_tier_syntax() {
let query = r#"CREATE TABLE warehouse (
id INTEGER PRIMARY KEY,
type TEXT NOT NULL)
USING memtx
DISTRIBUTED BY (id)
IN TIER "default";"#;
let metadata = &RouterConfigurationMock::new();
let plan = AbstractSyntaxTree::transform_into_plan(query, metadata);
assert!(plan.is_ok());
let query = r#"CREATE TABLE warehouse (
id INTEGER PRIMARY KEY,
type TEXT NOT NULL)
USING memtx
DISTRIBUTED BY (id)
IN TIER;"#;
let metadata = &RouterConfigurationMock::new();
let plan = AbstractSyntaxTree::transform_into_plan(query, metadata);
assert!(plan.is_err());
}
#[test]
fn front_alter_system_check_parses_ok() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment