mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-04-02 08:59:08 +02:00
test: wait rather than assert presence of file in startupnotify test
Should fix #23967.
This commit is contained in:
parent
1aabbf33d7
commit
96eb0093d0
@ -26,7 +26,7 @@ class StartupNotifyTest(BitcoinTestFramework):
|
||||
|
||||
self.log.info("Test -startupnotify command is run when node starts")
|
||||
self.restart_node(0, extra_args=[f"-startupnotify=echo '{FILE_NAME}' >> {NODE_DIR}/{FILE_NAME}"])
|
||||
assert os.path.exists(tmpdir_file)
|
||||
self.wait_until(lambda: os.path.exists(tmpdir_file))
|
||||
|
||||
self.log.info("Test -startupnotify is executed once")
|
||||
with open(tmpdir_file, "r", encoding="utf8") as f:
|
||||
|
Loading…
x
Reference in New Issue
Block a user