In API tests, replace no more working `uses_test_history` decorator (because
the `history_id` method parameter is interpreted as a fixture) with a real
class-level pytest fixture.
As a consequence, replace use of `self.history_id` in API tests because it
interferes with the class-level `history_id` fixture.
Also:
- Some type annotations
Upgrade syntax using `pyupgrade --py36-plus` .
Manually drop several `six` imports.
Also:
- Remove broken pr_cache in scripts/bootstrap_history.py
- Fix broken prefix removal in lib/galaxy/tool_util/deps/mulled/mulled_build.py
I've been refactoring toward this for at least half a decade. Being able to pip install the API and Selenium tests without bringing in the whole app is important to make them usable outside the context of the app - for testing remote, running servers for instance.
If galaxy-test-driver is available the test cases will still spawn a Galaxy instance if needed, but this is not longer required for import or use.