test: Avoid intermittent timeout in feature_assumevalid.py
Summary:
Currently the test will spin up p2p connections in the beginning, then announce the headers to all nodes, but only send the blocks sequentially. This takes a long time, so when getting to the last node, it will have already timed out, while node1 is busy eating blocks.
Fix this by only spinning up the p2p connection right before they are needed.
This is a backport of core#26651
Test Plan: ninja check-functional
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Differential Revision: https://reviews.bitcoinabc.org/D17620