summaryrefslogtreecommitdiff
path: root/tests/unittests/test_reporting_hyperv.py
diff options
context:
space:
mode:
authorDaniel Watkins <oddbloke@ubuntu.com>2020-07-13 12:00:32 -0400
committerGitHub <noreply@github.com>2020-07-13 12:00:32 -0400
commit3cec3881062490727c5fff1b16b53f0176f976f0 (patch)
treea26576249a456556bfe2557d273af5192bd41985 /tests/unittests/test_reporting_hyperv.py
parentfecbd81889011e8a75badd18935297f3494fe485 (diff)
downloadvyos-cloud-init-3cec3881062490727c5fff1b16b53f0176f976f0.tar.gz
vyos-cloud-init-3cec3881062490727c5fff1b16b53f0176f976f0.zip
cloudinit: remove global disable of pylint W0105 and fix errors (#480)
This includes a fix to a test that had a string concatenation issue, and so was only testing a prefix of what was intended.
Diffstat (limited to 'tests/unittests/test_reporting_hyperv.py')
-rw-r--r--tests/unittests/test_reporting_hyperv.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/unittests/test_reporting_hyperv.py b/tests/unittests/test_reporting_hyperv.py
index b60a66ab..bacf5da9 100644
--- a/tests/unittests/test_reporting_hyperv.py
+++ b/tests/unittests/test_reporting_hyperv.py
@@ -139,8 +139,10 @@ class TextKvpReporter(CiTestCase):
@mock.patch('cloudinit.subp.subp')
def test_get_boot_telemetry(self, m_subp, m_sysd):
reporter = HyperVKvpReportingHandler(kvp_file_path=self.tmp_file_path)
- datetime_pattern = r"\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]"
- r"\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z)"
+ datetime_pattern = (
+ r"\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]"
+ r"\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z)"
+ )
# get_boot_telemetry makes two subp calls to systemctl. We provide
# a list of values that the subp calls should return