test: remove unnecessary block rehashing prior to solving
Summary:
Solving a block involves continously rehashing it, i.e. any extra
calls to rehash it before are not necessary and can be dropped.
This is a backport of core#23498
Test Plan: ninja check-functional
Reviewers: #bitcoin_abc, roqqit
Reviewed By: #bitcoin_abc, roqqit
Differential Revision: https://reviews.bitcoinabc.org/D17690