From 57c25f9af0d7cc159e75eee5dbf74fee9b2ab28b Mon Sep 17 00:00:00 2001 From: Adam King Date: Wed, 23 Aug 2023 17:24:13 -0400 Subject: [PATCH] cephadm: fixups for unit tests These fixes really should be part of the commits that brought in/changed the tests, but it's difficult to find the exact commits as part of this batch backport so I'm doing these minor fixups in their own commit Signed-off-by: Adam King --- src/cephadm/tests/test_cephadm.py | 1 + src/cephadm/tests/test_util_funcs.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cephadm/tests/test_cephadm.py b/src/cephadm/tests/test_cephadm.py index f7d5fab3044ea..1267da985099a 100644 --- a/src/cephadm/tests/test_cephadm.py +++ b/src/cephadm/tests/test_cephadm.py @@ -362,6 +362,7 @@ class TestCephAdm(object): @mock.patch('cephadm.get_deployment_container') @mock.patch('cephadm.read_configuration_source', lambda c: {}) @mock.patch('cephadm.apply_deploy_config_to_ctx', lambda d, c: None) + @mock.patch('cephadm.extract_uid_gid', lambda *args, **kwargs: ('ceph', 'ceph')) def test_mon_crush_location(self, _get_deployment_container, _migrate_sysctl, _make_var_run, _fetch_configs, _deploy_daemon, _file_lock, _logger): """ test that crush location for mon is set if it is included in config_json diff --git a/src/cephadm/tests/test_util_funcs.py b/src/cephadm/tests/test_util_funcs.py index d7b173090b6f0..270753a554b86 100644 --- a/src/cephadm/tests/test_util_funcs.py +++ b/src/cephadm/tests/test_util_funcs.py @@ -781,7 +781,7 @@ class CompareContext2: def check(self, ctx): assert ctx.name == 'cc2' assert ctx.fsid == 'foobar' - assert ctx.image == 'quay.ceph.io/ceph-ci/ceph:main' + assert ctx.image == 'quay.io/ceph/ceph:v18' assert ctx.meta_properties == {"fruit": "banana", "vegetable": "carrot"} assert ctx.config_blobs == { "alpha": {"sloop": "John B"}, -- 2.39.5