Problem
test_the_recovery_advice_names_a_form_the_parser_accepts (added in #1222) carries this comment:
This needs no network: the destination is validated first, and an unparseable argument is rejected before that.
That is true of its first run, and false of its second. The retry names elsewhere, a path that does not exist — so it parses, passes the destination check, creates the folder and downloads the release. --profile puts it in the suite's top five:
14.45s test_install_downloads_the_latest_version
14.28s test_install_downloads_in_given_folder
11.66s test_install_downloads_the_given_version
10.73s test_do_not_update_on_consecutive_calls
10.27s test_the_recovery_advice_names_a_form_the_parser_accepts <-- this one
The other four download on purpose; this one does not need to. It also makes the test fail without internet, which its own comment says it does not require.
Fix
Point the retry at a second blocked path. What the assertion actually needs is proof that the parser accepted the form — reaching the destination check is that proof, since that is the stage after parsing. Locally 10.27s → 1.58s, most of which is bashunit startup.
Not filed, for the record
Two things this profiling run turned up that did not survive checking, so nobody re-chases them:
bashunit::env::active_internet_connection runs curl -sfI https://github.com with no --max-time. Real, but no other curl in the repo sets one either, and I could not produce a stall — the probe measured 218–299 ms.- Its
ping -c 1 -W 3 fallback: macOS man ping documents -W as milliseconds while GNU ping reads it as seconds, so the intended 3-second guard is 3 ms on macOS. The semantics differ, but -W 3 and -W 3000 succeeded equally often here (2/3 each), so there is no demonstrated failure to fix.
Problem
test_the_recovery_advice_names_a_form_the_parser_accepts(added in #1222) carries this comment:That is true of its first run, and false of its second. The retry names
elsewhere, a path that does not exist — so it parses, passes the destination check, creates the folder and downloads the release.--profileputs it in the suite's top five:The other four download on purpose; this one does not need to. It also makes the test fail without internet, which its own comment says it does not require.
Fix
Point the retry at a second blocked path. What the assertion actually needs is proof that the parser accepted the form — reaching the destination check is that proof, since that is the stage after parsing. Locally 10.27s → 1.58s, most of which is bashunit startup.
Not filed, for the record
Two things this profiling run turned up that did not survive checking, so nobody re-chases them:
bashunit::env::active_internet_connectionrunscurl -sfI https://github.comwith no--max-time. Real, but no othercurlin the repo sets one either, and I could not produce a stall — the probe measured 218–299 ms.ping -c 1 -W 3fallback: macOSman pingdocuments-Was milliseconds while GNU ping reads it as seconds, so the intended 3-second guard is 3 ms on macOS. The semantics differ, but-W 3and-W 3000succeeded equally often here (2/3 each), so there is no demonstrated failure to fix.