diff --git a/convert2rhel/subscription.py b/convert2rhel/subscription.py index 44126d939..85a1221c9 100644 --- a/convert2rhel/subscription.py +++ b/convert2rhel/subscription.py @@ -509,6 +509,7 @@ def download_rhsm_pkgs(): "dnf-plugin-subscription-manager", "python3-syspurpose", "python3-cloud-what", + "json-c.x86_64", # there's also an i686 version which we don't need ] _download_rhsm_pkgs(pkgs_to_download, _UBI_8_REPO_PATH, _UBI_8_REPO_CONTENT) diff --git a/convert2rhel/unit_tests/subscription_test.py b/convert2rhel/unit_tests/subscription_test.py index 639a850f3..ed8fa6f7a 100644 --- a/convert2rhel/unit_tests/subscription_test.py +++ b/convert2rhel/unit_tests/subscription_test.py @@ -480,7 +480,7 @@ def __call__(self, pkgs_to_download, repo_path, repo_content): @pytest.mark.parametrize( ( "version", - "downloaded_pkgs", + "pkgs_to_download", ), ( ( @@ -514,19 +514,20 @@ def __call__(self, pkgs_to_download, repo_path, repo_content): "dnf-plugin-subscription-manager", "python3-syspurpose", "python3-cloud-what", + "json-c.x86_64", ) ), ), ), ) -def test_download_rhsm_pkgs(version, downloaded_pkgs, monkeypatch): +def test_download_rhsm_pkgs(version, pkgs_to_download, monkeypatch): monkeypatch.setattr(system_info, "version", Version(*version)) monkeypatch.setattr(subscription, "_download_rhsm_pkgs", DownloadRHSMPkgsMocked()) monkeypatch.setattr(utils, "mkdir_p", DumbCallable()) subscription.download_rhsm_pkgs() assert subscription._download_rhsm_pkgs.called == 1 - assert frozenset(subscription._download_rhsm_pkgs.pkgs_to_download) == downloaded_pkgs + assert frozenset(subscription._download_rhsm_pkgs.pkgs_to_download) == pkgs_to_download class TestUnregisteringSystem: