]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr: fix some flake8 complaints 52790/head
authorNizamudeen A <nia@redhat.com>
Mon, 31 Jul 2023 09:20:57 +0000 (14:50 +0530)
committerAdam Emerson <aemerson@redhat.com>
Thu, 3 Aug 2023 14:18:37 +0000 (10:18 -0400)
Signed-off-by: Nizamudeen A <nia@redhat.com>
(cherry picked from commit d199782fb5f3c22f1cd5fda6ddf1d64f40a92726)

Conflicts:
src/pybind/mgr/crash/module.py imports were not present

src/pybind/mgr/cephadm/tests/fixtures.py
src/pybind/mgr/cephadm/tests/test_upgrade.py

index 8c2e1cfbfbb621b734e87606474237445e5e336a..3e73cb59b085c111acad8b8e542c86a86053769e 100644 (file)
@@ -46,9 +46,9 @@ def with_cephadm_module(module_options=None, store=None):
     :param module_options: Set opts as if they were set before module.__init__ is called
     :param store: Set the store before module.__init__ is called
     """
-    with mock.patch("cephadm.module.CephadmOrchestrator.get_ceph_option", get_ceph_option),\
+    with mock.patch("cephadm.module.CephadmOrchestrator.get_ceph_option", get_ceph_option), \
             mock.patch("cephadm.services.osd.RemoveUtil._run_mon_cmd"), \
-            mock.patch('cephadm.module.CephadmOrchestrator.get_module_option_ex', get_module_option_ex),\
+            mock.patch('cephadm.module.CephadmOrchestrator.get_module_option_ex', get_module_option_ex), \
             mock.patch("cephadm.module.CephadmOrchestrator.get_osdmap"), \
             mock.patch("cephadm.module.CephadmOrchestrator.remote"), \
             mock.patch('cephadm.offline_watcher.OfflineHostWatcher.run'):
index 9368f4dc385b461e84ad24702d1ebce91cbb2cc3..88c441c96e951a96dac4eb6a481a5e04e2ca49fb 100644 (file)
@@ -46,11 +46,11 @@ def test_upgrade_run(use_repo_digest, cephadm_module: CephadmOrchestrator):
             cephadm_module.set_container_image('global', 'from_image')
             cephadm_module.use_repo_digest = use_repo_digest
             with with_service(cephadm_module, ServiceSpec('mgr', placement=PlacementSpec(host_pattern='*', count=2)),
-                              CephadmOrchestrator.apply_mgr, '', status_running=True),\
+                              CephadmOrchestrator.apply_mgr, '', status_running=True), \
                 mock.patch("cephadm.module.CephadmOrchestrator.lookup_release_name",
-                           return_value='foo'),\
+                           return_value='foo'), \
                 mock.patch("cephadm.module.CephadmOrchestrator.version",
-                           new_callable=mock.PropertyMock) as version_mock,\
+                           new_callable=mock.PropertyMock) as version_mock, \
                 mock.patch("cephadm.module.CephadmOrchestrator.get",
                            return_value={
                                # capture fields in both mon and osd maps