diff options
author | Joshua Harlow <harlowja@yahoo-inc.com> | 2013-05-03 15:05:45 -0700 |
---|---|---|
committer | Joshua Harlow <harlowja@yahoo-inc.com> | 2013-05-03 15:05:45 -0700 |
commit | 9a1584b701cecbbba4a9371542114bcc806ec596 (patch) | |
tree | c293dcc8eea656f8d39b37d958794115b053eae2 | |
parent | 5118a33b22a376954bd048c3142f2d3f7f55d003 (diff) | |
download | vyos-cloud-init-9a1584b701cecbbba4a9371542114bcc806ec596.tar.gz vyos-cloud-init-9a1584b701cecbbba4a9371542114bcc806ec596.zip |
A few pep8/pylint cleanups.
-rw-r--r-- | cloudinit/mergers/m_dict.py | 7 | ||||
-rw-r--r-- | cloudinit/mergers/m_list.py | 2 | ||||
-rw-r--r-- | tests/unittests/test_merging.py | 2 |
3 files changed, 4 insertions, 7 deletions
diff --git a/cloudinit/mergers/m_dict.py b/cloudinit/mergers/m_dict.py index 82caa004..a16141fa 100644 --- a/cloudinit/mergers/m_dict.py +++ b/cloudinit/mergers/m_dict.py @@ -46,11 +46,8 @@ class Merger(object): def __str__(self): s = ('DictMerger: (method=%s,recurse_str=%s,' 'recurse_dict=%s,recurse_array=%s,allow_delete=%s)') - s = s % (self._method, - self._recurse_str, - self._recurse_dict, - self._recurse_array, - self._allow_delete) + s = s % (self._method, self._recurse_str, + self._recurse_dict, self._recurse_array, self._allow_delete) return s def _do_dict_replace(self, value, merge_with, do_replace): diff --git a/cloudinit/mergers/m_list.py b/cloudinit/mergers/m_list.py index 34b32379..8a0b5827 100644 --- a/cloudinit/mergers/m_list.py +++ b/cloudinit/mergers/m_list.py @@ -47,7 +47,7 @@ class Merger(object): def _on_list(self, value, merge_with): if (self._method == 'replace' and not isinstance(merge_with, (tuple, list))): - return merge_with + return merge_with # Ok we now know that what we are merging with is a list or tuple. merged_list = [] diff --git a/tests/unittests/test_merging.py b/tests/unittests/test_merging.py index dd8c2eee..ac2ccad4 100644 --- a/tests/unittests/test_merging.py +++ b/tests/unittests/test_merging.py @@ -12,7 +12,7 @@ import os import re SOURCE_PAT = "source*.*yaml" -EXPECTED_PAT = "expected%s.yaml" +EXPECTED_PAT = "expected%s.yaml" def _old_mergedict(src, cand): |