Minor de-duplication in test_workflows.py API tests.