From ce91b86be8777147b2e87069699b520d6e35acae Mon Sep 17 00:00:00 2001 From: Wagner Macedo Date: Mon, 3 Apr 2023 21:19:35 +0200 Subject: [PATCH] improve test_add_keyboard_interrupt_restore_content --- tests/console/commands/test_add.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/console/commands/test_add.py b/tests/console/commands/test_add.py index 366d6d606f2..5c2a1bafe1f 100644 --- a/tests/console/commands/test_add.py +++ b/tests/console/commands/test_add.py @@ -2159,7 +2159,8 @@ def test_add_keyboard_interrupt_restore_content( tester = command_tester_factory("add", poetry=poetry_with_up_to_date_lockfile) mocker.patch( - "poetry.installation.installer.Installer.run", side_effect=KeyboardInterrupt() + "poetry.installation.installer.Installer._execute", + side_effect=KeyboardInterrupt(), ) original_pyproject_content = poetry_with_up_to_date_lockfile.file.read() original_lockfile_content = poetry_with_up_to_date_lockfile._locker.lock_data