diff options
author | Chad Smith <chad.smith@canonical.com> | 2022-02-11 07:34:43 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-11 08:34:43 -0600 |
commit | 6dc67d732a92536dd42947af60cf4bfb25411489 (patch) | |
tree | d126110846469a8a5e0d32941757e7a25ddbb240 | |
parent | deb3ae828ea88090931c4cfe47957ae044f18ca8 (diff) | |
download | vyos-cloud-init-6dc67d732a92536dd42947af60cf4bfb25411489.tar.gz vyos-cloud-init-6dc67d732a92536dd42947af60cf4bfb25411489.zip |
test_apt_security: azure platform has specific security URL overrides (#1263)
Delivered in /etc/cloud/cloud.cfg.d/90-azure.cfg
-rw-r--r-- | tests/integration_tests/modules/test_apt.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/integration_tests/modules/test_apt.py b/tests/integration_tests/modules/test_apt.py index 48f398d1..adab46a8 100644 --- a/tests/integration_tests/modules/test_apt.py +++ b/tests/integration_tests/modules/test_apt.py @@ -267,10 +267,14 @@ class TestDefaults: sources_list = class_client.read_from_file("/etc/apt/sources.list") # 3 lines from main, universe, and multiverse - assert 3 == sources_list.count("deb http://security.ubuntu.com/ubuntu") - assert 3 == sources_list.count( - "# deb-src http://security.ubuntu.com/ubuntu" - ) + sec_url = "deb http://security.ubuntu.com/ubuntu" + if class_client.settings.PLATFORM == "azure": + sec_url = ( + "deb http://azure.archive.ubuntu.com/ubuntu/ jammy-security" + ) + sec_src_url = sec_url.replace("deb ", "# deb-src ") + assert 3 == sources_list.count(sec_url) + assert 3 == sources_list.count(sec_src_url) DEFAULT_DATA_WITH_URI = _DEFAULT_DATA.format( |