diff options
Diffstat (limited to 'library/cpp/yt/string/unittests/format_ut.cpp')
| -rw-r--r-- | library/cpp/yt/string/unittests/format_ut.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/library/cpp/yt/string/unittests/format_ut.cpp b/library/cpp/yt/string/unittests/format_ut.cpp index 5ec4a1ffa8b..f783efcf11a 100644 --- a/library/cpp/yt/string/unittests/format_ut.cpp +++ b/library/cpp/yt/string/unittests/format_ut.cpp @@ -246,6 +246,13 @@ TEST(TFormatTest, Tuples) EXPECT_EQ("{1, 2}", Format("%v", std::pair(1, 2))); } +TEST(TFormatTest, CompactIntervalView) +{ + EXPECT_EQ("[]", Format("%v", MakeCompactIntervalView(std::vector<int>{}))); + EXPECT_EQ("[1]", Format("%v", MakeCompactIntervalView(std::vector<int>{1}))); + EXPECT_EQ("[0, 2-4, 7]", Format("%v", MakeCompactIntervalView(std::vector<int>{0, 2, 3, 4, 7}))); +} + TEST(TFormatTest, LazyMultiValueFormatter) { int i = 1; |
