Skip to content

Commit 99bd033

Browse files
author
Vladislav Gogov
authored
Added test with disabled feature flag "EnableOlapCompression" (#9077)
1 parent c559bb3 commit 99bd033

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

ydb/core/kqp/ut/common/kqp_ut_common.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,12 @@ TKikimrRunner::TKikimrRunner(const TKikimrSettings& settings) {
133133
ServerSettings->SetUseRealThreads(settings.UseRealThreads);
134134
ServerSettings->SetEnableTablePgTypes(true);
135135
ServerSettings->SetEnablePgSyntax(true);
136-
ServerSettings->SetEnableOlapCompression(true);
137136
ServerSettings->S3ActorsFactory = settings.S3ActorsFactory;
138137

138+
if (!settings.FeatureFlags.HasEnableOlapCompression()) {
139+
ServerSettings->SetEnableOlapCompression(true);
140+
}
141+
139142
if (settings.Storage) {
140143
ServerSettings->SetCustomDiskParams(*settings.Storage);
141144
ServerSettings->SetEnableMockOnSingleNode(false);

ydb/core/kqp/ut/olap/sys_view_ut.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,17 @@ Y_UNIT_TEST_SUITE(KqpOlapSysView) {
219219
}
220220
}
221221

222+
Y_UNIT_TEST(DisabledAlterCompression) {
223+
TKikimrSettings settings = TKikimrSettings().SetWithSampleTables(false).SetEnableOlapCompression(false);
224+
TKikimrRunner kikimr(settings);
225+
TTypedLocalHelper helper("", kikimr, "olapTable", "olapStore");
226+
helper.CreateTestOlapTable();
227+
helper.FillPKOnly(0, 1);
228+
helper.ExecuteSchemeQuery(
229+
"ALTER OBJECT `/Root/olapStore` (TYPE TABLESTORE) SET (ACTION=ALTER_COLUMN, NAME=pk_int, "
230+
"`SERIALIZER.CLASS_NAME`=`ARROW_SERIALIZER`, `COMPRESSION.TYPE`=`zstd`);", NYdb::EStatus::PRECONDITION_FAILED);
231+
}
232+
222233
Y_UNIT_TEST(StatsSysViewBytesColumnActualization) {
223234
ui64 rawBytes1;
224235
ui64 bytes1;

0 commit comments

Comments
 (0)