mirror of
https://pagure.io/fm-orchestrator.git
synced 2026-05-01 22:21:04 +08:00
Move config.py to common/config.py
This commit is contained in:
@@ -244,7 +244,7 @@ def test_validate_koji_tag_is_None():
|
||||
|
||||
|
||||
@patch(
|
||||
"module_build_service.config.Config.allowed_privileged_module_names",
|
||||
"module_build_service.common.config.Config.allowed_privileged_module_names",
|
||||
new_callable=PropertyMock,
|
||||
return_value=["testmodule"],
|
||||
)
|
||||
@@ -300,7 +300,7 @@ def test_get_rpm_release_platform_stream_override():
|
||||
|
||||
|
||||
@patch(
|
||||
"module_build_service.config.Config.allowed_privileged_module_names",
|
||||
"module_build_service.common.config.Config.allowed_privileged_module_names",
|
||||
new_callable=PropertyMock,
|
||||
return_value=["build"],
|
||||
)
|
||||
|
||||
@@ -874,12 +874,12 @@ class TestKojiBuilder:
|
||||
db_session.commit()
|
||||
|
||||
with patch(
|
||||
"module_build_service.config.Config.koji_enable_content_generator",
|
||||
"module_build_service.common.config.Config.koji_enable_content_generator",
|
||||
new_callable=mock.PropertyMock,
|
||||
return_value=cg_enabled,
|
||||
):
|
||||
with patch(
|
||||
"module_build_service.config.Config.koji_cg_devel_module",
|
||||
"module_build_service.common.config.Config.koji_cg_devel_module",
|
||||
new_callable=mock.PropertyMock,
|
||||
return_value=cg_devel_enabled,
|
||||
):
|
||||
|
||||
@@ -194,7 +194,7 @@ class TestMockModuleBuilderAddRepos:
|
||||
|
||||
@mock.patch("module_build_service.conf.system", new="mock")
|
||||
@mock.patch(
|
||||
"module_build_service.config.Config.base_module_repofiles",
|
||||
"module_build_service.common.config.Config.base_module_repofiles",
|
||||
new_callable=mock.PropertyMock,
|
||||
return_value=["/etc/yum.repos.d/bar.repo", "/etc/yum.repos.d/bar-updates.repo"],
|
||||
create=True,
|
||||
@@ -308,12 +308,14 @@ class TestOfflineLocalBuilds:
|
||||
|
||||
|
||||
@mock.patch(
|
||||
"module_build_service.config.Config.mock_resultsdir",
|
||||
"module_build_service.common.config.Config.mock_resultsdir",
|
||||
new_callable=mock.PropertyMock,
|
||||
return_value=staged_data_filename("local_builds")
|
||||
)
|
||||
@mock.patch(
|
||||
"module_build_service.config.Config.system", new_callable=mock.PropertyMock, return_value="mock"
|
||||
"module_build_service.common.config.Config.system",
|
||||
new_callable=mock.PropertyMock,
|
||||
return_value="mock",
|
||||
)
|
||||
class TestLocalBuilds:
|
||||
def setup_method(self):
|
||||
|
||||
Reference in New Issue
Block a user