aboutsummaryrefslogtreecommitdiffstats
path: root/util/stream/hex_ut.cpp
diff options
context:
space:
mode:
authorpkalinnikov <pkalinnikov@yandex-team.ru>2022-02-10 16:50:15 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:50:15 +0300
commit9e33e026829d561d6fd46d72b88c367952e08075 (patch)
tree2af190fca83ac522e9a7e29de1daae32582064b4 /util/stream/hex_ut.cpp
parentba5325cc01aabb81effc91ff1bdbb461313cbd00 (diff)
downloadydb-9e33e026829d561d6fd46d72b88c367952e08075.tar.gz
Restoring authorship annotation for <pkalinnikov@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'util/stream/hex_ut.cpp')
-rw-r--r--util/stream/hex_ut.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/util/stream/hex_ut.cpp b/util/stream/hex_ut.cpp
index 5074a0b616..1a6bf5a6d3 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("");
+ }
+}