diff options
author | Gonéri Le Bouder <goneri@lebouder.net> | 2020-03-25 13:44:10 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-25 13:44:10 -0400 |
commit | 993f3e3e76e56266a83776a8f54dbb3ba59cfce7 (patch) | |
tree | a7226ed8f85b6a8b09c14d923bc08aadf5a1c11b /cloudinit/tests | |
parent | 42f69f410ab8850c02b1f53dd67c132aa8ef64f5 (diff) | |
download | vyos-cloud-init-993f3e3e76e56266a83776a8f54dbb3ba59cfce7.tar.gz vyos-cloud-init-993f3e3e76e56266a83776a8f54dbb3ba59cfce7.zip |
set_passwords: avoid chpasswd on BSD (#268)
Avoid chpasswd on all the BSD variants.
Diffstat (limited to 'cloudinit/tests')
-rw-r--r-- | cloudinit/tests/test_util.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cloudinit/tests/test_util.py b/cloudinit/tests/test_util.py index 877ab5c5..bfccfe1e 100644 --- a/cloudinit/tests/test_util.py +++ b/cloudinit/tests/test_util.py @@ -441,13 +441,15 @@ class TestGetLinuxDistro(CiTestCase): @mock.patch('platform.system') @mock.patch('platform.release') @mock.patch('cloudinit.util._parse_redhat_release') - def test_get_linux_freebsd(self, m_path_exists, m_platform_release, - m_platform_system, m_parse_redhat_release): + def test_get_linux_freebsd(self, m_parse_redhat_release, + m_platform_release, + m_platform_system, m_path_exists): """Verify we get the correct name and release name on FreeBSD.""" m_path_exists.return_value = False m_platform_release.return_value = '12.0-RELEASE-p10' m_platform_system.return_value = 'FreeBSD' m_parse_redhat_release.return_value = {} + util.is_BSD.cache_clear() dist = util.get_linux_distro() self.assertEqual(('freebsd', '12.0-RELEASE-p10', ''), dist) |