[refactor] clarify tests by referencing p2p objects directly
Summary:
Use object returned from add_p2p_connection to refer to
p2ps. Add a test class attribute if it needs to be used across
many methods. Don't use the p2p property.
This is a backport of core#19804 [1a/4]
https://github.com/bitcoin/bitcoin/pull/19804/commits/784f757994c1306bb6584b14c0c78617d6248432
abc* test will be done separately.
Test Plan: ninja check-functional-extended
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Subscribers: Fabien
Differential Revision: https://reviews.bitcoinabc.org/D10320