tests.utils: Test from modules using this need to call close method
This allows the clients to be written properly and their tests to pass.
To allow to write properly the swh.search client journal (which needs to call close
when done).
and its test to pass.
Related to swh-search!19 (closed)
Depends on !138 (closed)
Test Plan
tox
Migrated from D2901 (view on Phabricator)