summaryrefslogtreecommitdiffstats
path: root/searchcore/src/tests/proton/index
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2019-12-03 12:58:34 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2019-12-04 15:59:11 +0000
commit3abd363e0bf07f0467fb9f66815833330f68b223 (patch)
treeedcdd7ca18b348606bc324b6046b6ef15be820ad /searchcore/src/tests/proton/index
parent4136ec96afc319fa272970cd65acd633283a63d7 (diff)
Hide implementation to reduce FastOS_ visibility.
Diffstat (limited to 'searchcore/src/tests/proton/index')
-rw-r--r--searchcore/src/tests/proton/index/indexmanager_test.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/searchcore/src/tests/proton/index/indexmanager_test.cpp b/searchcore/src/tests/proton/index/indexmanager_test.cpp
index 2f5d3e353db..51e12e70dda 100644
--- a/searchcore/src/tests/proton/index/indexmanager_test.cpp
+++ b/searchcore/src/tests/proton/index/indexmanager_test.cpp
@@ -1,7 +1,5 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
-#include <vespa/document/fieldvalue/document.h>
-#include <vespa/document/fieldvalue/fieldvalue.h>
#include <vespa/fastos/file.h>
#include <vespa/searchcore/proton/index/indexmanager.h>
#include <vespa/searchcore/proton/server/executorthreadingservice.h>
@@ -19,12 +17,11 @@
#include <vespa/searchlib/memoryindex/field_inverter.h>
#include <vespa/searchlib/queryeval/isourceselector.h>
#include <vespa/searchlib/test/index/mock_field_length_inspector.h>
-#include <vespa/searchlib/util/dirtraverse.h>
#include <vespa/vespalib/gtest/gtest.h>
#include <vespa/vespalib/io/fileutil.h>
-#include <vespa/vespalib/util/blockingthreadstackexecutor.h>
#include <vespa/vespalib/util/threadstackexecutor.h>
#include <set>
+#include <thread>
#include <vespa/log/log.h>
LOG_SETUP("indexmanager_test");
@@ -57,6 +54,7 @@ using vespalib::makeLambdaTask;
using namespace proton;
using namespace searchcorespi;
using namespace searchcorespi::index;
+using namespace std::chrono_literals;
namespace {
@@ -303,7 +301,7 @@ TEST_F(IndexManagerTest, require_that_memory_index_is_flushed)
EXPECT_EQ(stat._modifiedTime, target.getLastFlushTime().timeSinceEpoch().time());
// updated serial number & flush time when nothing to flush
- FastOS_Thread::Sleep(8000);
+ std::this_thread::sleep_for(8s);
fastos::TimeStamp now = fastos::ClockSystem::now().timeSinceEpoch();
vespalib::Executor::Task::UP task;
runAsMaster([&]() { task = target.initFlush(2); });