diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2020-01-03 10:47:26 +0000 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2020-01-03 10:47:26 +0000 |
commit | c1b1440c4eb7d997a4ed8bc07a6e18b9e09007c2 (patch) | |
tree | c45023a71a228761c3d6da014e7a9ad2f4eb32de /searchlib/src | |
parent | e549978610aa127df17492d80d892742de6fd479 (diff) |
Update tests after changing how executors are selected.
Diffstat (limited to 'searchlib/src')
-rw-r--r-- | searchlib/src/tests/common/sequencedtaskexecutor/sequencedtaskexecutor_test.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/searchlib/src/tests/common/sequencedtaskexecutor/sequencedtaskexecutor_test.cpp b/searchlib/src/tests/common/sequencedtaskexecutor/sequencedtaskexecutor_test.cpp index f8ab03d7710..77caf535405 100644 --- a/searchlib/src/tests/common/sequencedtaskexecutor/sequencedtaskexecutor_test.cpp +++ b/searchlib/src/tests/common/sequencedtaskexecutor/sequencedtaskexecutor_test.cpp @@ -101,7 +101,7 @@ TEST_F("require that task with different component ids are not serialized", Fixt std::shared_ptr<TestObj> tv(std::make_shared<TestObj>()); EXPECT_EQUAL(0, tv->_val); f._threads.execute(0, [=]() { usleep(2000); tv->modify(0, 14); }); - f._threads.execute(2, [=]() { tv->modify(14, 42); }); + f._threads.execute(1, [=]() { tv->modify(14, 42); }); tv->wait(2); if (tv->_fail != 1) { continue; @@ -173,16 +173,14 @@ vespalib::string makeAltComponentId(Fixture &f) } -TEST_F("require that task with different string component ids are not serialized", - Fixture) +TEST_F("require that task with different string component ids are not serialized", Fixture) { - int tryCnt = detectSerializeFailure(f, "2", 100); + int tryCnt = detectSerializeFailure(f, "1", 100); EXPECT_TRUE(tryCnt < 100); } -TEST_F("require that task with different string component ids mapping to the same executor id are serialized", - Fixture) +TEST_F("require that task with different string component ids mapping to the same executor id are serialized", Fixture) { vespalib::string altComponentId = makeAltComponentId(f); LOG(info, "second string component id is \"%s\"", altComponentId.c_str()); |