diff options
author | Arne Juul <arnej@verizonmedia.com> | 2021-02-15 13:55:04 +0000 |
---|---|---|
committer | Arne Juul <arnej@verizonmedia.com> | 2021-02-15 14:16:21 +0000 |
commit | af9d59c3fece374c5fe61575c67ad49ac5f84bb4 (patch) | |
tree | a1851a855e22e406f877bfb405e192232ec1e137 /searchcore/src/tests/proton/index | |
parent | 805a313df05d2f347af321511527e06ea3cae92c (diff) |
use size literals in searchcore
Diffstat (limited to 'searchcore/src/tests/proton/index')
-rw-r--r-- | searchcore/src/tests/proton/index/indexcollection_test.cpp | 3 | ||||
-rw-r--r-- | searchcore/src/tests/proton/index/indexmanager_test.cpp | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/searchcore/src/tests/proton/index/indexcollection_test.cpp b/searchcore/src/tests/proton/index/indexcollection_test.cpp index 113901e893f..a0007027d51 100644 --- a/searchcore/src/tests/proton/index/indexcollection_test.cpp +++ b/searchcore/src/tests/proton/index/indexcollection_test.cpp @@ -3,6 +3,7 @@ #include <vespa/searchcore/proton/matching/fakesearchcontext.h> #include <vespa/searchcorespi/index/warmupindexcollection.h> #include <vespa/vespalib/gtest/gtest.h> +#include <vespa/vespalib/util/size_literals.h> #include <vespa/vespalib/util/threadstackexecutor.h> #include <vespa/log/log.h> @@ -87,7 +88,7 @@ public: _source1(new MockIndexSearchable({3, 5})), _source2(new MockIndexSearchable({7, 11})), _fusion_source(new FakeIndexSearchable), - _executor(1, 128*1024), + _executor(1, 128_Ki), _warmup(new FakeIndexSearchable) {} ~IndexCollectionTest() = default; diff --git a/searchcore/src/tests/proton/index/indexmanager_test.cpp b/searchcore/src/tests/proton/index/indexmanager_test.cpp index bb808879e80..a4e9b828870 100644 --- a/searchcore/src/tests/proton/index/indexmanager_test.cpp +++ b/searchcore/src/tests/proton/index/indexmanager_test.cpp @@ -20,6 +20,7 @@ #include <vespa/searchlib/test/index/mock_field_length_inspector.h> #include <vespa/vespalib/gtest/gtest.h> #include <vespa/vespalib/io/fileutil.h> +#include <vespa/vespalib/util/size_literals.h> #include <vespa/vespalib/util/threadstackexecutor.h> #include <vespa/vespalib/util/time.h> #include <set> @@ -316,7 +317,7 @@ TEST_F(IndexManagerTest, require_that_memory_index_is_flushed) TEST_F(IndexManagerTest, require_that_large_memory_footprint_triggers_urgent_flush) { using FlushStats = IndexMaintainer::FlushStats; - constexpr size_t G = 1024*1024*1024l; + constexpr size_t G =1_Gi; // IndexMaintainer::FlushStats small_15G(15*G, 0, 1, 1); EXPECT_FALSE(IndexFlushTarget(_index_manager->getMaintainer()).needUrgentFlush()); EXPECT_FALSE(IndexFlushTarget(_index_manager->getMaintainer(), FlushStats(15*G)).needUrgentFlush()); |