From 2acffc45c90db6db7a46b0dfaf54ac71c6d750fe Mon Sep 17 00:00:00 2001 From: Jamil RAICHOUNI Date: Mon, 7 Oct 2024 12:08:54 +0200 Subject: [PATCH] chore: Satisfy `pylint` --- capella/download_archive.py | 8 ++++---- tests/conftest.py | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/capella/download_archive.py b/capella/download_archive.py index 94cbb1c1..c218bc7c 100644 --- a/capella/download_archive.py +++ b/capella/download_archive.py @@ -44,18 +44,18 @@ def get_directory_structure(url: str) -> list[str]: version for version in versions if version.startswith(capella_version) ) - final_url = f"{CAPELLA_INDEX_URL}{capella_archive_path}" - dir_content = get_directory_structure(final_url) + FINAL_URL = f"{CAPELLA_INDEX_URL}{capella_archive_path}" + dir_content = get_directory_structure(FINAL_URL) archive_name = next( arch for arch in dir_content if arch.endswith("linux-gtk-x86_64.tar.gz") ) - download_url = CAPELLA_DOWNLOAD_URL.format( + DOWNLOAD_URL = CAPELLA_DOWNLOAD_URL.format( f"{capella_archive_path}{archive_name}" ) - download_response = requests.get(download_url) + download_response = requests.get(DOWNLOAD_URL) download_response.raise_for_status() download_path = pathlib.Path("/opt/capella.tar.gz").write_bytes( download_response.content diff --git a/tests/conftest.py b/tests/conftest.py index c08f8b25..b04aae67 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -194,6 +194,7 @@ def fixture_init_t4c_server_repo(t4c_ip_addr: str, t4c_http_port: str) -> None: create_t4c_repository(t4c_ip_addr, t4c_http_port) +# pylint: disable=too-many-positional-arguments @contextlib.contextmanager def get_container( image: str, @@ -240,6 +241,9 @@ def get_container( container.remove() +# pylint: enable=too-many-positional-arguments + + def wait_for_container( container: containers.Container, wait_for_message: str,