diff --git a/src/spoc_cli.py b/src/spoc_cli.py index bb68423..5075e80 100644 --- a/src/spoc_cli.py +++ b/src/spoc_cli.py @@ -26,7 +26,8 @@ def handle_repo_error(exception): else: ex_type = type(exception) reason = f'{ex_type.__module__}.{ex_type.__name__}' - print(f'Online repository cannot be reached due to: {reason}', file=sys.stderr) + print(f'Repository "{spoc.config.REGISTRY_HOST}" cannot be reached due to: {reason}', + file=sys.stderr) def listing(list_type): if list_type == 'installed': diff --git a/tests/test_cli.py b/tests/test_cli.py index 83efc33..489e444 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -40,7 +40,7 @@ def test_handle_app_error(exception, expected, capsys): spoc_cli.handle_repo_error(exception) captured = capsys.readouterr() - expected = f'Online repository cannot be reached due to: {expected}\n' + expected = f'Repository "{spoc.config.REGISTRY_HOST}" cannot be reached due to: {expected}\n' assert captured.err == expected @patch('spoc.list_installed', return_value={'anotherapp': '0.1', 'someapp': '0.1'})