diff options
author | Anton Samokhvalov <pg83@yandex.ru> | 2022-02-10 16:45:15 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:45:15 +0300 |
commit | 72cb13b4aff9bc9cf22e49251bc8fd143f82538f (patch) | |
tree | da2c34829458c7d4e74bdfbdf85dff449e9e7fb8 /library/cpp/packers/ut/packers_ut.cpp | |
parent | 778e51ba091dc39e7b7fcab2b9cf4dbedfb6f2b5 (diff) | |
download | ydb-72cb13b4aff9bc9cf22e49251bc8fd143f82538f.tar.gz |
Restoring authorship annotation for Anton Samokhvalov <pg83@yandex.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/packers/ut/packers_ut.cpp')
-rw-r--r-- | library/cpp/packers/ut/packers_ut.cpp | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/library/cpp/packers/ut/packers_ut.cpp b/library/cpp/packers/ut/packers_ut.cpp index 18ce2150d1..65a817f9b2 100644 --- a/library/cpp/packers/ut/packers_ut.cpp +++ b/library/cpp/packers/ut/packers_ut.cpp @@ -1,11 +1,11 @@ #include <library/cpp/testing/unittest/registar.h> - + #include <util/stream/output.h> #include <utility> - -#include <util/charset/wide.h> + +#include <util/charset/wide.h> #include <util/generic/algorithm.h> -#include <util/generic/buffer.h> +#include <util/generic/buffer.h> #include <util/generic/map.h> #include <util/generic/vector.h> #include <util/generic/ptr.h> @@ -13,19 +13,19 @@ #include <util/folder/dirut.h> -#include <util/random/random.h> - +#include <util/random/random.h> + #include <util/string/hex.h> #include "packers.h" - + #include <array> #include <iterator> -class TPackersTest: public TTestBase { +class TPackersTest: public TTestBase { private: UNIT_TEST_SUITE(TPackersTest); - UNIT_TEST(TestPackers); + UNIT_TEST(TestPackers); UNIT_TEST_SUITE_END(); template <class TData, class TPacker> @@ -66,44 +66,44 @@ void TPackersTest::TestPacker(const TData* test, size_t size) { void TPackersTest::TestPackers() { { - const TString test[] = {"", - "a", "b", "c", "d", - "aa", "ab", "ac", "ad", - "aaa", "aab", "aac", "aad", - "aba", "abb", "abc", "abd", - "asdfjjmk.gjilsjgilsjilgjildsajgfilsjdfilgjm ldsa8oq43u 583uq4905 -q435 jiores u893q 5oiju fd-KE 89536 9Q2URE 12AI894T3 89 Q*(re43"}; + const TString test[] = {"", + "a", "b", "c", "d", + "aa", "ab", "ac", "ad", + "aaa", "aab", "aac", "aad", + "aba", "abb", "abc", "abd", + "asdfjjmk.gjilsjgilsjilgjildsajgfilsjdfilgjm ldsa8oq43u 583uq4905 -q435 jiores u893q 5oiju fd-KE 89536 9Q2URE 12AI894T3 89 Q*(re43"}; - TestPacker<TString, NPackers::TPacker<TString>>(test, Y_ARRAY_SIZE(test)); + TestPacker<TString, NPackers::TPacker<TString>>(test, Y_ARRAY_SIZE(test)); for (size_t i = 0; i != Y_ARRAY_SIZE(test); ++i) { - TestPacker<TUtf16String, NPackers::TPacker<TUtf16String>>(UTF8ToWide(test[i])); + TestPacker<TUtf16String, NPackers::TPacker<TUtf16String>>(UTF8ToWide(test[i])); } } { const ui64 test[] = { - 0, 1, 2, 3, 4, 5, 6, 76, 100000, Max<ui64>()}; + 0, 1, 2, 3, 4, 5, 6, 76, 100000, Max<ui64>()}; - TestPacker<ui64, NPackers::TPacker<ui64>>(test, Y_ARRAY_SIZE(test)); + TestPacker<ui64, NPackers::TPacker<ui64>>(test, Y_ARRAY_SIZE(test)); } { const int test[] = { - 0, 1, 2, 3, 4, 5, 6, 76, 100000, -1, -2, -3, -4, -5, -6, -76, -10000, Min<int>(), Max<int>()}; + 0, 1, 2, 3, 4, 5, 6, 76, 100000, -1, -2, -3, -4, -5, -6, -76, -10000, Min<int>(), Max<int>()}; - TestPacker<int, NPackers::TPacker<int>>(test, Y_ARRAY_SIZE(test)); + TestPacker<int, NPackers::TPacker<int>>(test, Y_ARRAY_SIZE(test)); } { const float test[] = { 2.f, 3.f, 4.f, 0.f, -0.f, 1.f, -1.f, 1.1f, -1.1f, - std::numeric_limits<float>::min(), -std::numeric_limits<float>::min(), - std::numeric_limits<float>::max(), -std::numeric_limits<float>::max()}; + std::numeric_limits<float>::min(), -std::numeric_limits<float>::min(), + std::numeric_limits<float>::max(), -std::numeric_limits<float>::max()}; TestPacker<float, NPackers::TFloatPacker>(test, Y_ARRAY_SIZE(test)); } { const double test[] = { 0., -0., 1., -1., 1.1, -1.1, - std::numeric_limits<double>::min(), -std::numeric_limits<double>::min(), - std::numeric_limits<double>::max(), -std::numeric_limits<double>::max()}; + std::numeric_limits<double>::min(), -std::numeric_limits<double>::min(), + std::numeric_limits<double>::max(), -std::numeric_limits<double>::max()}; TestPacker<double, NPackers::TDoublePacker>(test, Y_ARRAY_SIZE(test)); } |