aboutsummaryrefslogtreecommitdiffstats
path: root/util/generic/algorithm_ut.cpp
diff options
context:
space:
mode:
authora-bocharov <a-bocharov@yandex-team.ru>2022-02-10 16:51:42 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:51:42 +0300
commite826ebc0dee525ef263356dece4e470c3303cc7a (patch)
treeab7fbbf3253d4c0e2793218f09378908beb025fb /util/generic/algorithm_ut.cpp
parentcf85d9ecf529a02f41258fd39cbc1a1cee24525d (diff)
downloadydb-e826ebc0dee525ef263356dece4e470c3303cc7a.tar.gz
Restoring authorship annotation for <a-bocharov@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'util/generic/algorithm_ut.cpp')
-rw-r--r--util/generic/algorithm_ut.cpp44
1 files changed, 22 insertions, 22 deletions
diff --git a/util/generic/algorithm_ut.cpp b/util/generic/algorithm_ut.cpp
index 87a41c89bb8..8d732fcc0cf 100644
--- a/util/generic/algorithm_ut.cpp
+++ b/util/generic/algorithm_ut.cpp
@@ -225,28 +225,28 @@ Y_UNIT_TEST_SUITE(TAlgorithm) {
UNIT_ASSERT_EQUAL(NPOS, FindIndex(empty, 0));
}
- Y_UNIT_TEST(FindIndexIfTest) {
- TVectorNoCopy v;
- v.push_back(1);
- v.push_back(2);
- v.push_back(3);
-
- UNIT_ASSERT_EQUAL(0, FindIndexIf(v, [](int x) { return x == 1; }));
- UNIT_ASSERT_EQUAL(1, FindIndexIf(v, [](int x) { return x == 2; }));
- UNIT_ASSERT_EQUAL(2, FindIndexIf(v, [](int x) { return x == 3; }));
- UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(v, [](int x) { return x == 42; }));
-
- int array[3] = {1, 2, 3};
-
- UNIT_ASSERT_EQUAL(0, FindIndexIf(array, [](int x) { return x == 1; }));
- UNIT_ASSERT_EQUAL(1, FindIndexIf(array, [](int x) { return x == 2; }));
- UNIT_ASSERT_EQUAL(2, FindIndexIf(array, [](int x) { return x == 3; }));
- UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(array, [](int x) { return x == 42; }));
-
- TVector<int> empty;
- UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(empty, [](int x) { return x == 3; }));
- }
-
+ Y_UNIT_TEST(FindIndexIfTest) {
+ TVectorNoCopy v;
+ v.push_back(1);
+ v.push_back(2);
+ v.push_back(3);
+
+ UNIT_ASSERT_EQUAL(0, FindIndexIf(v, [](int x) { return x == 1; }));
+ UNIT_ASSERT_EQUAL(1, FindIndexIf(v, [](int x) { return x == 2; }));
+ UNIT_ASSERT_EQUAL(2, FindIndexIf(v, [](int x) { return x == 3; }));
+ UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(v, [](int x) { return x == 42; }));
+
+ int array[3] = {1, 2, 3};
+
+ UNIT_ASSERT_EQUAL(0, FindIndexIf(array, [](int x) { return x == 1; }));
+ UNIT_ASSERT_EQUAL(1, FindIndexIf(array, [](int x) { return x == 2; }));
+ UNIT_ASSERT_EQUAL(2, FindIndexIf(array, [](int x) { return x == 3; }));
+ UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(array, [](int x) { return x == 42; }));
+
+ TVector<int> empty;
+ UNIT_ASSERT_EQUAL(NPOS, FindIndexIf(empty, [](int x) { return x == 3; }));
+ }
+
Y_UNIT_TEST(SortUniqueTest) {
{
TVector<TString> v;