summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenety Goh <benety@mongodb.com>2014-07-31 18:02:43 -0400
committerBenety Goh <benety@mongodb.com>2014-07-31 18:06:37 -0400
commit675063a05e18d6d0ab7d280c794d3b61e5e71b70 (patch)
tree1b3787932859f6fd7c7b802751d5f47b0c5c8688
parent7679e3e99f4f5153df219a0802f87e16cc47e3a1 (diff)
downloadmongo-675063a05e18d6d0ab7d280c794d3b61e5e71b70.tar.gz
SERVER-13760 added check on source collection size before running mongoexport
(cherry picked from commit 0f45edb3e83bef553ae70c4cbab4c08319f2fd61)
-rw-r--r--jstests/tool/exportimport_date.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/jstests/tool/exportimport_date.js b/jstests/tool/exportimport_date.js
index 81476471c2f..b9263e9e50e 100644
--- a/jstests/tool/exportimport_date.js
+++ b/jstests/tool/exportimport_date.js
@@ -18,6 +18,9 @@ var nonformatable = ISODate("3001-01-01T00:00:00Z");
assert.eq(nonformatable.valueOf(), 32535216000000);
src.insert({ "_id" : nonformatable });
+// Verify number of documents inserted
+assert.eq(2, src.find().itcount());
+
data = 'data/exportimport_date_test.json';
print('About to call mongoexport on: ' + exportimport_db.getName() + '.' + src.getName() +