diff options
author | Kaloian Manassiev <kaloian.manassiev@mongodb.com> | 2020-06-12 08:42:14 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-06-15 11:31:00 +0000 |
commit | e1d7052125a3ca7767a81c4737628ba37077d17b (patch) | |
tree | c330644ae88efef8a088cfdeb7b4344afb233992 /src/mongo/db/catalog/database_test.cpp | |
parent | a357a44eb10fe00e3fd4378b539ef36fa9fb3ccd (diff) | |
download | mongo-e1d7052125a3ca7767a81c4737628ba37077d17b.tar.gz |
SERVER-48775 Make OpObserverShardingImpl to be part of sharding_runtime_d
Diffstat (limited to 'src/mongo/db/catalog/database_test.cpp')
-rw-r--r-- | src/mongo/db/catalog/database_test.cpp | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/src/mongo/db/catalog/database_test.cpp b/src/mongo/db/catalog/database_test.cpp index 8a3baa12c34..70bb59651a3 100644 --- a/src/mongo/db/catalog/database_test.cpp +++ b/src/mongo/db/catalog/database_test.cpp @@ -31,7 +31,6 @@ #include <boost/optional/optional_io.hpp> #include <memory> - #include <pcrecpp.h> #include "mongo/bson/util/builder.h" @@ -47,6 +46,7 @@ #include "mongo/db/jsobj.h" #include "mongo/db/namespace_string.h" #include "mongo/db/op_observer.h" +#include "mongo/db/op_observer_impl.h" #include "mongo/db/op_observer_registry.h" #include "mongo/db/operation_context.h" #include "mongo/db/repl/drop_pending_collection_reaper.h" @@ -56,20 +56,14 @@ #include "mongo/db/repl/replication_coordinator.h" #include "mongo/db/repl/replication_coordinator_mock.h" #include "mongo/db/repl/storage_interface_mock.h" -#include "mongo/db/s/op_observer_sharding_impl.h" #include "mongo/db/service_context_d_test_fixture.h" #include "mongo/db/storage/durable_catalog.h" #include "mongo/unittest/unittest.h" #include "mongo/util/scopeguard.h" +namespace mongo { namespace { -using namespace mongo; - -ServiceContext::UniqueOperationContext makeOpCtx() { - return cc().makeOperationContext(); -} - class DatabaseTest : public ServiceContextMongoDTest { private: void setUp() override; @@ -106,7 +100,7 @@ void DatabaseTest::setUp() { // repl::logOp(). repl::logOp() will also store the oplog entry's optime in ReplClientInfo. OpObserverRegistry* opObserverRegistry = dynamic_cast<OpObserverRegistry*>(service->getOpObserver()); - opObserverRegistry->addObserver(std::make_unique<OpObserverShardingImpl>()); + opObserverRegistry->addObserver(std::make_unique<OpObserverImpl>()); _nss = NamespaceString("test.foo"); } @@ -554,5 +548,5 @@ TEST_F(DatabaseTest, CreateCollectionProhibitsReplicatedCollectionsWithoutIdInde }); } - } // namespace +} // namespace mongo |