From 7261d6cb457e60a3fff046086deab7a53eafd870 Mon Sep 17 00:00:00 2001 From: Chris Peterson Date: Mon, 2 Oct 2023 14:37:39 -0700 Subject: [PATCH] tests: remove obsolete commands --- subiquity/server/controllers/tests/test_filesystem.py | 4 ---- subiquity/server/controllers/tests/test_install.py | 4 ---- subiquity/server/controllers/tests/test_refresh.py | 2 -- subiquity/server/controllers/tests/test_snaplist.py | 2 -- 4 files changed, 12 deletions(-) diff --git a/subiquity/server/controllers/tests/test_filesystem.py b/subiquity/server/controllers/tests/test_filesystem.py index cf6cb6bba..af0ded36d 100644 --- a/subiquity/server/controllers/tests/test_filesystem.py +++ b/subiquity/server/controllers/tests/test_filesystem.py @@ -89,8 +89,6 @@ class TestSubiquityControllerFilesystem(IsolatedAsyncioTestCase): def setUp(self): self.app = make_app() self.app.opts.bootloader = "UEFI" - self.app.report_start_event = mock.Mock() - self.app.report_finish_event = mock.Mock() self.app.prober = mock.Mock() self.app.prober.get_storage = mock.AsyncMock() self.app.block_log_dir = "/inexistent" @@ -1149,8 +1147,6 @@ def setUp(self): self.app = make_app() self.app.command_runner = mock.AsyncMock() self.app.opts.bootloader = "UEFI" - self.app.report_start_event = mock.Mock() - self.app.report_finish_event = mock.Mock() self.app.prober = mock.Mock() self.app.prober.get_storage = mock.AsyncMock() self.app.snapdapi = snapdapi.make_api_client(AsyncSnapd(get_fake_connection())) diff --git a/subiquity/server/controllers/tests/test_install.py b/subiquity/server/controllers/tests/test_install.py index 00c91e01d..51b40412a 100644 --- a/subiquity/server/controllers/tests/test_install.py +++ b/subiquity/server/controllers/tests/test_install.py @@ -34,8 +34,6 @@ def setUp(self): self.controller = InstallController(make_app()) self.controller.write_config = unittest.mock.Mock() self.controller.app.note_file_for_apport = Mock() - self.controller.app.report_start_event = Mock() - self.controller.app.report_finish_event = Mock() self.controller.model.target = "/target" @@ -199,8 +197,6 @@ def test_generic_config(self): class TestInstallController(unittest.IsolatedAsyncioTestCase): def setUp(self): self.controller = InstallController(make_app()) - self.controller.app.report_start_event = Mock() - self.controller.app.report_finish_event = Mock() self.controller.model.target = tempfile.mkdtemp() os.makedirs(os.path.join(self.controller.model.target, "etc/grub.d")) self.addCleanup(shutil.rmtree, self.controller.model.target) diff --git a/subiquity/server/controllers/tests/test_refresh.py b/subiquity/server/controllers/tests/test_refresh.py index 94adf24d6..0da98fbfa 100644 --- a/subiquity/server/controllers/tests/test_refresh.py +++ b/subiquity/server/controllers/tests/test_refresh.py @@ -26,8 +26,6 @@ class TestRefreshController(SubiTestCase): def setUp(self): self.app = make_app() - self.app.report_start_event = mock.Mock() - self.app.report_finish_event = mock.Mock() self.app.note_data_for_apport = mock.Mock() self.app.prober = mock.Mock() self.app.snapdapi = snapdapi.make_api_client(AsyncSnapd(get_fake_connection())) diff --git a/subiquity/server/controllers/tests/test_snaplist.py b/subiquity/server/controllers/tests/test_snaplist.py index a31e8e5ac..78f2af49c 100644 --- a/subiquity/server/controllers/tests/test_snaplist.py +++ b/subiquity/server/controllers/tests/test_snaplist.py @@ -31,8 +31,6 @@ def setUp(self): self.model = SnapListModel() self.app = make_app() self.app.snapd = AsyncMock() - self.app.report_start_event = Mock() - self.app.report_finish_event = Mock() self.loader = SnapdSnapInfoLoader( self.model, self.app.snapd, "server", self.app.context