diff options
author | pkalinnikov <[email protected]> | 2022-02-10 16:50:15 +0300 |
---|---|---|
committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:50:15 +0300 |
commit | d507a9366b2ab84411afe63fea9fba5498891e1b (patch) | |
tree | 5d5cb817648f650d76cf1076100726fd9b8448e8 /util/stream/hex_ut.cpp | |
parent | 9e33e026829d561d6fd46d72b88c367952e08075 (diff) |
Restoring authorship annotation for <[email protected]>. Commit 2 of 2.
Diffstat (limited to 'util/stream/hex_ut.cpp')
-rw-r--r-- | util/stream/hex_ut.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/util/stream/hex_ut.cpp b/util/stream/hex_ut.cpp index 1a6bf5a6d3b..5074a0b6168 100644 --- a/util/stream/hex_ut.cpp +++ b/util/stream/hex_ut.cpp @@ -1,29 +1,29 @@ -#include "hex.h" - +#include "hex.h" + #include <library/cpp/testing/unittest/registar.h> #include "str.h" - + Y_UNIT_TEST_SUITE(THexCodingTest) { void TestImpl(const TString& data) { TString encoded; - TStringOutput encodedOut(encoded); + TStringOutput encodedOut(encoded); HexEncode(data.data(), data.size(), encodedOut); - + UNIT_ASSERT_EQUAL(encoded.size(), data.size() * 2); - + TString decoded; - TStringOutput decodedOut(decoded); + TStringOutput decodedOut(decoded); HexDecode(encoded.data(), encoded.size(), decodedOut); - - UNIT_ASSERT_EQUAL(decoded, data); - } - + + UNIT_ASSERT_EQUAL(decoded, data); + } + Y_UNIT_TEST(TestEncodeDecodeToStream) { TString data = "100ABAcaba500,$%0987123456 \n\t\x01\x02\x03."; - TestImpl(data); - } - + TestImpl(data); + } + Y_UNIT_TEST(TestEmpty) { - TestImpl(""); - } -} + TestImpl(""); + } +} |