aboutsummaryrefslogtreecommitdiffstats
path: root/yt/cpp/mapreduce/interface/ut/common_ut.cpp
diff options
context:
space:
mode:
authorermolovd <ermolovd@yandex-team.com>2024-09-19 21:14:13 +0300
committerermolovd <ermolovd@yandex-team.com>2024-09-19 21:25:01 +0300
commit1c463c12c42bc4a7071b8a1fc530e5b87d3dca9c (patch)
tree5ec1cd1d68ba79f7bbe31f5259e766dcb3bb4ec3 /yt/cpp/mapreduce/interface/ut/common_ut.cpp
parent5ce9b712aa7fd8eacab0c51a076f9b8cacad3ca3 (diff)
downloadydb-1c463c12c42bc4a7071b8a1fc530e5b87d3dca9c.tar.gz
Fix: reset RawTypeV3, when Type is set (and vice versa)
commit_hash:af63b4f5a0c2db692a0224330b79c5088c6982dc
Diffstat (limited to 'yt/cpp/mapreduce/interface/ut/common_ut.cpp')
-rw-r--r--yt/cpp/mapreduce/interface/ut/common_ut.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/yt/cpp/mapreduce/interface/ut/common_ut.cpp b/yt/cpp/mapreduce/interface/ut/common_ut.cpp
index 85122a97ec..f15fa22e21 100644
--- a/yt/cpp/mapreduce/interface/ut/common_ut.cpp
+++ b/yt/cpp/mapreduce/interface/ut/common_ut.cpp
@@ -351,3 +351,15 @@ TEST(TCommonTest, TableSchemaEquality)
other.UniqueKeys(false);
ASSERT_SERIALIZABLES_NE(other, schema);
}
+
+TEST(TCommonTest, ModificationLoadedSchema)
+{
+ auto schema = TTableSchema::FromNode(NodeFromYsonString(R"""(
+ [{name=foo;type_v3=string}]
+ )"""));
+ schema.MutableColumns()[0].Type(VT_INT64, true);
+
+ Cerr << NodeToYsonString(schema.ToNode()) << Endl;
+
+ ASSERT_EQ(schema.ToNode()[0]["type"].AsString(), "int64");
+}