aboutsummaryrefslogtreecommitdiff
path: root/test/functional/mempool_persist.py
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2018-04-08 12:46:12 -0400
committerMarcoFalke <falke.marco@gmail.com>2018-04-08 12:44:43 -0400
commitfab9095d4071159f88eeefa5c1a750960fd2fbb9 (patch)
treeb8f6a3f8be32bfa0ea6c8ab9fa9098771a754368 /test/functional/mempool_persist.py
parent15c3bb4268f3366c26a1ba28d32216f2ff86fe7f (diff)
qa: Windows fixups for functional tests
Diffstat (limited to 'test/functional/mempool_persist.py')
-rwxr-xr-xtest/functional/mempool_persist.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/functional/mempool_persist.py b/test/functional/mempool_persist.py
index 75eb9b1784..83dffb0521 100755
--- a/test/functional/mempool_persist.py
+++ b/test/functional/mempool_persist.py
@@ -107,13 +107,13 @@ class MempoolPersistTest(BitcoinTestFramework):
wait_until(lambda: len(self.nodes[1].getrawmempool()) == 5)
self.log.debug("Prevent bitcoind from writing mempool.dat to disk. Verify that `savemempool` fails")
- # to test the exception we are setting bad permissions on a tmp file called mempool.dat.new
+ # to test the exception we are creating a tmp folder called mempool.dat.new
# which is an implementation detail that could change and break this test
mempooldotnew1 = mempooldat1 + '.new'
- with os.fdopen(os.open(mempooldotnew1, os.O_CREAT, 0o000), 'w'):
- pass
+ os.mkdir(mempooldotnew1)
assert_raises_rpc_error(-1, "Unable to dump mempool to disk", self.nodes[1].savemempool)
- os.remove(mempooldotnew1)
+ os.rmdir(mempooldotnew1)
+
if __name__ == '__main__':
MempoolPersistTest().main()