diff options
author | Henning Baldersheim <balder@oath.com> | 2018-09-24 11:50:47 +0200 |
---|---|---|
committer | Henning Baldersheim <balder@oath.com> | 2018-09-24 11:50:47 +0200 |
commit | 85491d4ce0d186321e2c8a34f62ae13cadd6d5a4 (patch) | |
tree | f06b1f7ff8f82b657fe57df0eb433fc244602a74 /searchlib/src/tests/docstore/document_store | |
parent | 963ede37edb248accf9eba715d83eca45c8804b9 (diff) |
Update comments and tests as memory size has increased by 8 bytes per entry in the cache.
Diffstat (limited to 'searchlib/src/tests/docstore/document_store')
-rw-r--r-- | searchlib/src/tests/docstore/document_store/document_store_test.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/searchlib/src/tests/docstore/document_store/document_store_test.cpp b/searchlib/src/tests/docstore/document_store/document_store_test.cpp index 16acbdfe878..649fb675dca 100644 --- a/searchlib/src/tests/docstore/document_store/document_store_test.cpp +++ b/searchlib/src/tests/docstore/document_store/document_store_test.cpp @@ -102,8 +102,15 @@ void verifyValue(vespalib::stringref s, const Value & v) { EXPECT_EQUAL(0, memcmp(s.data(), result.first.getData(), result.first.getDataLen())); } -TEST("require that Value can store uncompressed data") { +TEST("require that Value and cache entries have expected size") { + using pair = std::pair<DocumentIdT, Value>; + using Node = vespalib::hash_node<pair>; EXPECT_EQUAL(64ul, sizeof(Value)); + EXPECT_EQUAL(72ul, sizeof(pair)); + EXPECT_EQUAL(80ul, sizeof(Node)); +} + +TEST("require that Value can store uncompressed data") { Value v = createValue(S1, CompressionConfig::NONE); verifyValue(S1, v); } |