cloud-init-dev team mailing list archive
-
cloud-init-dev team
-
Mailing list archive
-
Message #04995
[Merge] ~chad.smith/cloud-init:tests/disable-chrony-on-lxd-artful into cloud-init:master
Chad Smith has proposed merging ~chad.smith/cloud-init:tests/disable-chrony-on-lxd-artful into cloud-init:master.
Commit message:
tests: skip chrony integration tests on lxd running artful or older
A fix for chrony support per LP: #1589780 is not expected in Artful or
older series. Skip the chrony suite of tests when running on a container
and ubuntu series represented is <= artful as errors are expected.
Requested reviews:
cloud-init commiters (cloud-init-dev)
For more details, see:
https://code.launchpad.net/~chad.smith/cloud-init/+git/cloud-init/+merge/347824
--
Your team cloud-init commiters is requested to review the proposed merge of ~chad.smith/cloud-init:tests/disable-chrony-on-lxd-artful into cloud-init:master.
diff --git a/tests/cloud_tests/testcases/modules/ntp_chrony.py b/tests/cloud_tests/testcases/modules/ntp_chrony.py
index 461630a..7a115c9 100644
--- a/tests/cloud_tests/testcases/modules/ntp_chrony.py
+++ b/tests/cloud_tests/testcases/modules/ntp_chrony.py
@@ -1,13 +1,25 @@
# This file is part of cloud-init. See LICENSE file for license information.
"""cloud-init Integration Test Verify Script."""
+import unittest
+
from tests.cloud_tests.testcases import base
class TestNtpChrony(base.CloudTestCase):
"""Test ntp module with chrony client"""
- def test_chrony_entires(self):
+
+ def setUp(self):
+ """Skip this suite of tests on lxd and artful or older."""
+ if self.platform != 'nocloud-kvm':
+ if self.is_distro('ubuntu') and self.os_version_cmp('artful') <= 0:
+ raise unittest.SkipTest(
+ 'No support for chrony on containers <= artful.'
+ ' LP: #1589780')
+ return super(TestNtpChrony, self).setUp()
+
+ def test_chrony_entries(self):
"""Test chrony config entries"""
out = self.get_data_file('chrony_conf')
self.assertIn('.pool.ntp.org', out)
Follow ups