Skip to content

Commit 15b508b

Browse files
committed
Fixed topic metric tests
1 parent 75e7a8f commit 15b508b

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

tests/integration/topic/describe_topic.cpp

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,11 @@ TEST_F(Describe, TEST_NAME(Location)) {
120120
}
121121

122122
TEST_F(Describe, TEST_NAME(MetricsLevel)) {
123+
char* ydbVersion = std::getenv("YDB_VERSION");
124+
if (ydbVersion != nullptr && std::string(ydbVersion) != "trunk") {
125+
GTEST_SKIP() << "Skipping test for YDB version " << ydbVersion;
126+
}
127+
123128
TTopicClient client(MakeDriver());
124129

125130
// const std::uint32_t MetricsLevelDisabled = 0;
@@ -149,7 +154,7 @@ TEST_F(Describe, TEST_NAME(MetricsLevel)) {
149154
};
150155

151156
{
152-
const std::string topic("topic-with-counters");
157+
const std::string topic(GetTopicPath("topic-with-counters"));
153158
createTopic(topic, MetricsLevelDetailed);
154159
checkFlag(topic, MetricsLevelDetailed);
155160
setMetricsLevel(topic, MetricsLevelObject);
@@ -169,7 +174,7 @@ TEST_F(Describe, TEST_NAME(MetricsLevel)) {
169174
}
170175

171176
{
172-
const std::string topic("topic-without-counters-by-default");
177+
const std::string topic(GetTopicPath("topic-without-counters-by-default"));
173178
auto res = client.CreateTopic(topic).GetValueSync();
174179
ASSERT_TRUE(res.IsSuccess());
175180
Y_ENSURE(checkFlag(topic, {}));
@@ -185,7 +190,7 @@ TEST_F(Describe, TEST_NAME(MetricsLevel)) {
185190
}
186191

187192
{
188-
const std::string topic("topic-without-counters");
193+
const std::string topic(GetTopicPath("topic-without-counters"));
189194
createTopic(topic, MetricsLevelObject);
190195
Y_ENSURE(checkFlag(topic, MetricsLevelObject));
191196
setMetricsLevel(topic, MetricsLevelDetailed);

0 commit comments

Comments
 (0)