summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorsueloverso <sue@mongodb.com>2017-04-05 13:29:48 -0400
committerDon Anderson <dda@mongodb.com>2017-04-05 13:29:48 -0400
commit3be0fb108d0cc6e22b83ed59f8ea1108f05c4b43 (patch)
tree7680c20c261b4e61c83a1270e4f33e1525cdc870 /test
parentf071bba27f3d431677b8530dd0e7aab620161ce3 (diff)
downloadmongo-3be0fb108d0cc6e22b83ed59f8ea1108f05c4b43.tar.gz
WT-3253 Update Python transaction tests to have correct flush configuration (#3368)
Diffstat (limited to 'test')
-rw-r--r--test/suite/test_txn02.py5
-rw-r--r--test/suite/test_txn05.py5
-rw-r--r--test/suite/test_txn07.py5
3 files changed, 12 insertions, 3 deletions
diff --git a/test/suite/test_txn02.py b/test/suite/test_txn02.py
index 01626057b9e..0ab05baea36 100644
--- a/test/suite/test_txn02.py
+++ b/test/suite/test_txn02.py
@@ -137,7 +137,10 @@ class test_txn02(wttest.WiredTigerTestCase, suite_subprocess):
self.check(self.session2, "isolation=read-uncommitted", current)
# Opening a clone of the database home directory should run
- # recovery and see the committed results.
+ # recovery and see the committed results. Flush the log because
+ # the backup may not get all the log records if we are running
+ # without a sync option. Use sync=off to force a write to the OS.
+ self.session.log_flush('sync=off')
self.backup(self.backup_dir)
backup_conn_params = 'log=(enabled,file_max=%s)' % self.logmax
backup_conn = self.wiredtiger_open(self.backup_dir, backup_conn_params)
diff --git a/test/suite/test_txn05.py b/test/suite/test_txn05.py
index 7aaff221ba4..c1902404f8d 100644
--- a/test/suite/test_txn05.py
+++ b/test/suite/test_txn05.py
@@ -101,7 +101,10 @@ class test_txn05(wttest.WiredTigerTestCase, suite_subprocess):
self.check(self.session2, "isolation=read-uncommitted", current)
# Opening a clone of the database home directory should run
- # recovery and see the committed results.
+ # recovery and see the committed results. Flush the log because
+ # the backup may not get all the log records if we are running
+ # without a sync option. Use sync=off to force a write to the OS.
+ self.session.log_flush('sync=off')
self.backup(self.backup_dir)
backup_conn_params = 'log=(enabled,file_max=%s)' % self.logmax
backup_conn = self.wiredtiger_open(self.backup_dir, backup_conn_params)
diff --git a/test/suite/test_txn07.py b/test/suite/test_txn07.py
index e26cf5aaaea..ffb6ecfbecb 100644
--- a/test/suite/test_txn07.py
+++ b/test/suite/test_txn07.py
@@ -112,7 +112,10 @@ class test_txn07(wttest.WiredTigerTestCase, suite_subprocess):
self.check(self.session2, "isolation=read-uncommitted", current)
# Opening a clone of the database home directory should run
- # recovery and see the committed results.
+ # recovery and see the committed results. Flush the log because
+ # the backup may not get all the log records if we are running
+ # without a sync option. Use sync=off to force a write to the OS.
+ self.session.log_flush('sync=off')
self.backup(self.backup_dir)
backup_conn_params = 'log=(enabled,file_max=%s,' % self.logmax + \
'compressor=%s)' % self.compress + \