diff options
author | Tor Brede Vekterli <vekterli@yahoo-inc.com> | 2017-10-20 13:36:16 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-20 13:36:16 +0200 |
commit | 5fd803fe826569265db2f76d327610ac829ed7ea (patch) | |
tree | d7a341f9f71afe98c2704218a88a5cf47a93374b /document/src | |
parent | c29d5f06c591d303ef37ae75ab6e306ea3314bd5 (diff) | |
parent | 5b37d8b706055661ab68e8b2dee96cdedeaf0c72 (diff) |
Merge pull request #3808 from vespa-engine/toregge/add-bucket-space-to-storage-commands-pass4
Adjust constructors for more storage commands to use document::Bucket
Diffstat (limited to 'document/src')
4 files changed, 32 insertions, 0 deletions
diff --git a/document/src/vespa/document/CMakeLists.txt b/document/src/vespa/document/CMakeLists.txt index 8d6999fdc24..7ae341f6d4b 100644 --- a/document/src/vespa/document/CMakeLists.txt +++ b/document/src/vespa/document/CMakeLists.txt @@ -14,6 +14,7 @@ vespa_add_library(document $<TARGET_OBJECTS:document_repo> $<TARGET_OBJECTS:document_serialization> $<TARGET_OBJECTS:document_predicate> + $<TARGET_OBJECTS:document_test> INSTALL lib64 DEPENDS ) diff --git a/document/src/vespa/document/test/CMakeLists.txt b/document/src/vespa/document/test/CMakeLists.txt new file mode 100644 index 00000000000..f16bfe0144a --- /dev/null +++ b/document/src/vespa/document/test/CMakeLists.txt @@ -0,0 +1,6 @@ +# Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +vespa_add_library(document_test OBJECT + SOURCES + make_document_bucket.cpp + DEPENDS +) diff --git a/document/src/vespa/document/test/make_document_bucket.cpp b/document/src/vespa/document/test/make_document_bucket.cpp new file mode 100644 index 00000000000..f4d22f7b83f --- /dev/null +++ b/document/src/vespa/document/test/make_document_bucket.cpp @@ -0,0 +1,12 @@ +// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. + +#include "make_document_bucket.h" + +namespace document::test { + +Bucket makeDocumentBucket(BucketId bucketId) +{ + return Bucket(BucketSpace::placeHolder(), bucketId); +} + +} diff --git a/document/src/vespa/document/test/make_document_bucket.h b/document/src/vespa/document/test/make_document_bucket.h new file mode 100644 index 00000000000..8c7411cc0e8 --- /dev/null +++ b/document/src/vespa/document/test/make_document_bucket.h @@ -0,0 +1,13 @@ +// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. + +#pragma once + +#include <vespa/document/bucket/bucket.h> + +namespace document::test { + +// Helper function used by unit tests + +Bucket makeDocumentBucket(BucketId bucketId); + +} |