summaryrefslogtreecommitdiff
path: root/src/mongo/db/storage/record_store_test_datafor.cpp
diff options
context:
space:
mode:
authorMathias Stearn <mathias@10gen.com>2014-11-26 15:04:26 -0500
committerMathias Stearn <mathias@10gen.com>2014-11-26 15:15:59 -0500
commit16a8ef7ad60d498b69bdc0ad5cbca44757d16fd8 (patch)
tree2d9f056acf8f1b9b2e943f82e315bdf019475a38 /src/mongo/db/storage/record_store_test_datafor.cpp
parentcb5cab88761d9aca75e064665cce89f579c69e36 (diff)
downloadmongo-16a8ef7ad60d498b69bdc0ad5cbca44757d16fd8.tar.gz
SERVER-13679 Replace DiskLoc with RecordId outside of MMAPv1
Operations: sed -i -e 's/\<DiskLoc\>/RecordId/g' sed -i -e 's/\<DiskLocs\>/RecordIds/g' sed -i -e 's/\<minDiskLoc\>/RecordId::min()/g' sed -i -e 's/\<maxDiskLoc\>/RecordId::max()/g' sed -i -e 's/\<getDiskLoc\>/getRecordId/g'' Changes under mmap_v1 were reverted and redone by hand as needed.
Diffstat (limited to 'src/mongo/db/storage/record_store_test_datafor.cpp')
-rw-r--r--src/mongo/db/storage/record_store_test_datafor.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mongo/db/storage/record_store_test_datafor.cpp b/src/mongo/db/storage/record_store_test_datafor.cpp
index 82f445fd2ab..13acd9270ee 100644
--- a/src/mongo/db/storage/record_store_test_datafor.cpp
+++ b/src/mongo/db/storage/record_store_test_datafor.cpp
@@ -41,7 +41,7 @@ using std::stringstream;
namespace mongo {
// Insert a record and verify its contents by calling dataFor()
- // on the returned DiskLoc.
+ // on the returned RecordId.
TEST( RecordStoreTestHarness, DataFor ) {
scoped_ptr<HarnessHelper> harnessHelper( newHarnessHelper() );
scoped_ptr<RecordStore> rs( harnessHelper->newNonCappedRecordStore() );
@@ -52,12 +52,12 @@ namespace mongo {
}
string data = "record-";
- DiskLoc loc;
+ RecordId loc;
{
scoped_ptr<OperationContext> opCtx( harnessHelper->newOperationContext() );
{
WriteUnitOfWork uow( opCtx.get() );
- StatusWith<DiskLoc> res = rs->insertRecord( opCtx.get(),
+ StatusWith<RecordId> res = rs->insertRecord( opCtx.get(),
data.c_str(),
data.size() + 1,
false );
@@ -83,7 +83,7 @@ namespace mongo {
}
// Insert multiple records and verify their contents by calling dataFor()
- // on each of the returned DiskLocs.
+ // on each of the returned RecordIds.
TEST( RecordStoreTestHarness, DataForMultiple ) {
scoped_ptr<HarnessHelper> harnessHelper( newHarnessHelper() );
scoped_ptr<RecordStore> rs( harnessHelper->newNonCappedRecordStore() );
@@ -94,7 +94,7 @@ namespace mongo {
}
const int nToInsert = 10;
- DiskLoc locs[nToInsert];
+ RecordId locs[nToInsert];
for ( int i = 0; i < nToInsert; i++ ) {
scoped_ptr<OperationContext> opCtx( harnessHelper->newOperationContext() );
{
@@ -103,7 +103,7 @@ namespace mongo {
string data = ss.str();
WriteUnitOfWork uow( opCtx.get() );
- StatusWith<DiskLoc> res = rs->insertRecord( opCtx.get(),
+ StatusWith<RecordId> res = rs->insertRecord( opCtx.get(),
data.c_str(),
data.size() + 1,
false );