From 0b8e7c280a17762109625ba3dd3793241bb57d33 Mon Sep 17 00:00:00 2001 From: Chenxiong Qi Date: Oct 20 2017 06:03:53 +0000 Subject: Do not read real koji config in test Signed-off-by: Chenxiong Qi --- diff --git a/tests/test_cli.py b/tests/test_cli.py index 7ca2370..cb9d847 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -1911,10 +1911,13 @@ class TestModulesCli(CliTestCase): @patch('sys.stdout', new=StringIO()) @patch('requests.get') - def test_module_build_info(self, mock_get): + @patch('pyrpkg.Commands.kojiweburl', new_callable=PropertyMock) + def test_module_build_info(self, kojiweburl, mock_get): """ Test getting information on a module build """ + kojiweburl.return_value = 'https://koji.example.org/koji' + cli_cmd = [ 'rpkg', '--path', @@ -1948,7 +1951,7 @@ Components: Name: module-build-macros NVR: module-build-macros-None-None State: FAILED - Koji Task: https://koji.fedoraproject.org/koji/taskinfo?taskID=22370514 + Koji Task: https://koji.example.org/koji/taskinfo?taskID=22370514 Name: python-dns NVR: None