diff options
author | vvvv <[email protected]> | 2025-10-06 11:26:09 +0300 |
---|---|---|
committer | vvvv <[email protected]> | 2025-10-06 11:53:26 +0300 |
commit | 60f45e69a4d7dbc6131208e16c45faf35aa5a985 (patch) | |
tree | 4daa45b52c295a178c7620e4c93921465fcf7950 /yql/essentials/utils/md5_stream_ut.cpp | |
parent | 1bded1a65a7e6e9171418f3e1c691d390125b64e (diff) |
YQL-20086 utils
init
commit_hash:54feccd520ebd0ab23612bc0cb830914dff9d0e8
Diffstat (limited to 'yql/essentials/utils/md5_stream_ut.cpp')
-rw-r--r-- | yql/essentials/utils/md5_stream_ut.cpp | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/yql/essentials/utils/md5_stream_ut.cpp b/yql/essentials/utils/md5_stream_ut.cpp index 1d04c632d49..a120e83eda0 100644 --- a/yql/essentials/utils/md5_stream_ut.cpp +++ b/yql/essentials/utils/md5_stream_ut.cpp @@ -17,31 +17,31 @@ TString Consume(const TString& input) { UNIT_ASSERT_VALUES_EQUAL(input, output); return md5Stream.Finalize(); } -} +} // namespace Y_UNIT_TEST_SUITE(TStreamMd5Tests) { - Y_UNIT_TEST(Empty) { - const auto md5 = Consume(""); - const TString emptyStringMd5 = "d41d8cd98f00b204e9800998ecf8427e"; - UNIT_ASSERT_VALUES_EQUAL(md5, emptyStringMd5); - } +Y_UNIT_TEST(Empty) { + const auto md5 = Consume(""); + const TString emptyStringMd5 = "d41d8cd98f00b204e9800998ecf8427e"; + UNIT_ASSERT_VALUES_EQUAL(md5, emptyStringMd5); +} - Y_UNIT_TEST(ShortText) { - const auto md5 = Consume("hello from Y!"); - const TString expectedMd5 = "abf59ed7b0daa71085e76e461a737cc2"; - UNIT_ASSERT_VALUES_EQUAL(md5, expectedMd5); - } +Y_UNIT_TEST(ShortText) { + const auto md5 = Consume("hello from Y!"); + const TString expectedMd5 = "abf59ed7b0daa71085e76e461a737cc2"; + UNIT_ASSERT_VALUES_EQUAL(md5, expectedMd5); +} - Y_UNIT_TEST(BigText) { - // TransferData uses TempBuf of 64K - const TString s(1000000, 'A'); - const auto md5 = Consume(s.c_str()); - /* - $ for i in {1..1000000};do echo -n A >> 1M.txt;done - $ md5sum 1M.txt - 48fcdb8b87ce8ef779774199a856091d 1M.txt - */ - const TString expectedMd5 = "48fcdb8b87ce8ef779774199a856091d"; - UNIT_ASSERT_VALUES_EQUAL(md5, expectedMd5); - } +Y_UNIT_TEST(BigText) { + // TransferData uses TempBuf of 64K + const TString s(1000000, 'A'); + const auto md5 = Consume(s.c_str()); + /* + $ for i in {1..1000000};do echo -n A >> 1M.txt;done + $ md5sum 1M.txt + 48fcdb8b87ce8ef779774199a856091d 1M.txt + */ + const TString expectedMd5 = "48fcdb8b87ce8ef779774199a856091d"; + UNIT_ASSERT_VALUES_EQUAL(md5, expectedMd5); } +} // Y_UNIT_TEST_SUITE(TStreamMd5Tests) |