summaryrefslogtreecommitdiff
path: root/jstests/disk
diff options
context:
space:
mode:
Diffstat (limited to 'jstests/disk')
-rw-r--r--jstests/disk/wt_repair_corrupt_metadata.js15
1 files changed, 2 insertions, 13 deletions
diff --git a/jstests/disk/wt_repair_corrupt_metadata.js b/jstests/disk/wt_repair_corrupt_metadata.js
index 02fa8e37f79..6263b18825b 100644
--- a/jstests/disk/wt_repair_corrupt_metadata.js
+++ b/jstests/disk/wt_repair_corrupt_metadata.js
@@ -6,11 +6,6 @@
(function() {
- if (_isWindows()) {
- jsTestLog("Skipping test on Windows");
- return;
- }
-
load('jstests/disk/libs/wt_file_helper.js');
const baseName = "wt_repair_corrupt_metadata";
@@ -82,21 +77,15 @@
// Corrupt the .turtle file in a very specific way such that the log sequence numbers are
// invalid.
if (mongodOptions.hasOwnProperty('journal')) {
- // TODO: This return can be removed once WT-4310 is completed.
- if (isDebug) {
- jsTestLog("Skipping log file corruption because this is a debug build.");
- return;
- }
-
jsTestLog("Corrupting log file metadata");
- let data = cat(turtleFile);
+ let data = cat(turtleFile, true /* useBinaryMode */);
let re = /checkpoint_lsn=\(([0-9,]+)\)/g;
let newData = data.replace(re, "checkpoint_lsn=(1,2)");
print('writing data to new turtle file: \n' + newData);
removeFile(turtleFile);
- writeFile(turtleFile, newData);
+ writeFile(turtleFile, newData, true /* useBinaryMode */);
assertRepairSucceeds(dbpath, mongod.port, mongodOptions);