Consolidate creation of storage::spi::Bucket in unit tests.
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "bucketfactory.h"
+#include <vespa/persistence/spi/test.h>
using document::BucketId;
using document::DocumentId;
using storage::spi::Bucket;
using storage::spi::PartitionId;
+using storage::spi::test::makeBucket;
namespace proton {
@@ -21,7 +23,7 @@ BucketFactory::getBucketId(const DocumentId &docId)
Bucket
BucketFactory::getBucket(const DocumentId &docId)
{
- return Bucket(document::Bucket(document::BucketSpace::placeHolder(), getBucketId(docId)), PartitionId(0));
+ return makeBucket(getBucketId(docId));
}
} // namespace proton
