test: Add test to check tx in the last block can be downloaded
Summary:
If a peer received an inv about a transaction, which was included in a block before receiving the corresponding getdata, it can be beneficial to send this transaction to the peer to aid compact block relay.
Add a test for this to avoid breaking it in the future.
This is a backport of core#27695
Test Plan: ninja check-functional
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Differential Revision: https://reviews.bitcoinabc.org/D18366