diff options
Diffstat (limited to 'src/mongo/dbtests/counttests.cpp')
-rw-r--r-- | src/mongo/dbtests/counttests.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mongo/dbtests/counttests.cpp b/src/mongo/dbtests/counttests.cpp index 1ff84d735f8..729443e2835 100644 --- a/src/mongo/dbtests/counttests.cpp +++ b/src/mongo/dbtests/counttests.cpp @@ -41,13 +41,16 @@ namespace CountTests { class Base { + OperationContextImpl _txn; Lock::DBWrite lk; + Client::Context _context; + Database* _database; Collection* _collection; - OperationContextImpl _txn; + public: - Base() : lk(ns()), _context( ns() ) { + Base() : lk(_txn.lockState(), ns()), _context( ns() ) { _database = _context.db(); _collection = _database->getCollection( ns() ); if ( _collection ) { |