This moves wait_until to util.py to make it generally available to python tests.
Also, wait_until now takes an optional lock that is acquired while testing the predicate.
Previously the lock was always acquired, even when it was not necessary, cf. disconnect_ban.py.
qa: Move wait_until to util #11068
pull MarcoFalke wants to merge 1 commits into bitcoin:master from MarcoFalke:Mf1708-qaWaitUntilMiniNode changing 11 files +78 −89-
MarcoFalke commented at 4:18 PM on August 16, 2017: member
- MarcoFalke added the label Tests on Aug 16, 2017
- MarcoFalke force-pushed on Aug 17, 2017
-
qa: Move wait_until to util 08ce33f8e9
- MarcoFalke force-pushed on Aug 17, 2017
- MarcoFalke renamed this:
[WIP] qa: Replace wait_until with wait_until_mn (scripted)
qa: Move wait_until to util
on Aug 17, 2017 -
MarcoFalke commented at 4:39 PM on August 17, 2017: member
@jnewbery I pushed my preferred version. No need for unwanted intermediate commits.
On Aug 16, 2017 11:26 PM, "John Newbery" notifications@github.com wrote:
I don't love this name, but we can tidy up in a later commit so concept ACK (since it's required for #11067 https://github.com/bitcoin/bitcoin/pull/11067)
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/pull/11068#issuecomment-322904253, or mute the thread https://github.com/notifications/unsubscribe-auth/AGGmv4HFA4y15floZY_QxDOqIJxhqa46ks5sY16hgaJpZM4O5J4L .
-
jnewbery commented at 5:48 PM on August 17, 2017: member
Great! Tested ACK 08ce33f8e95efa81b37ddc6b3350462c61bbfd51 . I've long wanted to move the assert up into
wait_util(), but for some reason I thought there were more call sites where the return value wasn't being asserted.This is a good change.
wait_until()is a pure utility function and should live in util.py. The caller passing in the lock seems fine to me. - MarcoFalke merged this on Aug 23, 2017
- MarcoFalke closed this on Aug 23, 2017
- MarcoFalke referenced this in commit 8858b6ddd3 on Aug 23, 2017
- MarcoFalke deleted the branch on Aug 23, 2017
- MarcoFalke referenced this in commit 5398f205e3 on Oct 3, 2017
- PastaPastaPasta referenced this in commit 92ad824868 on Sep 19, 2019
- PastaPastaPasta referenced this in commit a2f418fc4f on Sep 19, 2019
- PastaPastaPasta referenced this in commit 9565b16a29 on Sep 23, 2019
- PastaPastaPasta referenced this in commit 7283bc6131 on Sep 24, 2019
- codablock referenced this in commit 956e6bc016 on Sep 24, 2019
- barrystyle referenced this in commit 96a20be204 on Jan 22, 2020
- DrahtBot locked this on Sep 8, 2021