summaryrefslogtreecommitdiff
path: root/tests/unittests/test_distros/test_generic.py
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2016-05-27 09:55:10 -0400
committerScott Moser <smoser@ubuntu.com>2016-05-27 09:55:10 -0400
commit318bd66461cba2f480b2ef6be119d2fcd5c6e9c0 (patch)
tree1817b310efc0190c92c5c95b15df6491119233ce /tests/unittests/test_distros/test_generic.py
parent949cebd48c9100d4fd00b74232bcf048980e6e0d (diff)
parent0dbe69aa34948d73d5709a7ddc19389e05e1a268 (diff)
downloadvyos-cloud-init-318bd66461cba2f480b2ef6be119d2fcd5c6e9c0.tar.gz
vyos-cloud-init-318bd66461cba2f480b2ef6be119d2fcd5c6e9c0.zip
merge from trunk
Diffstat (limited to 'tests/unittests/test_distros/test_generic.py')
-rw-r--r--tests/unittests/test_distros/test_generic.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/unittests/test_distros/test_generic.py b/tests/unittests/test_distros/test_generic.py
index 6ed1704c..96fa0811 100644
--- a/tests/unittests/test_distros/test_generic.py
+++ b/tests/unittests/test_distros/test_generic.py
@@ -87,13 +87,13 @@ class TestGenericDistro(helpers.FilesystemMockingTestCase):
rules = 'ALL=(ALL:ALL) ALL'
contents = self._write_load_sudoers('harlowja', rules)
expected = ['harlowja ALL=(ALL:ALL) ALL']
- self.assertEquals(len(expected), self._count_in(expected, contents))
+ self.assertEqual(len(expected), self._count_in(expected, contents))
not_expected = [
'harlowja A',
'harlowja L',
'harlowja L',
]
- self.assertEquals(0, self._count_in(not_expected, contents))
+ self.assertEqual(0, self._count_in(not_expected, contents))
def test_sudoers_ensure_rules_list(self):
rules = [
@@ -107,13 +107,13 @@ class TestGenericDistro(helpers.FilesystemMockingTestCase):
'harlowja B-ALL=(ALL:ALL) ALL',
'harlowja C-ALL=(ALL:ALL) ALL',
]
- self.assertEquals(len(expected), self._count_in(expected, contents))
+ self.assertEqual(len(expected), self._count_in(expected, contents))
not_expected = [
'harlowja A',
'harlowja L',
'harlowja L',
]
- self.assertEquals(0, self._count_in(not_expected, contents))
+ self.assertEqual(0, self._count_in(not_expected, contents))
def test_sudoers_ensure_new(self):
cls = distros.fetch("ubuntu")
@@ -136,7 +136,7 @@ class TestGenericDistro(helpers.FilesystemMockingTestCase):
self.assertIn("includedir /b", contents)
self.assertTrue(os.path.isdir("/b"))
self.assertIn("josh", contents)
- self.assertEquals(2, contents.count("josh"))
+ self.assertEqual(2, contents.count("josh"))
def test_arch_package_mirror_info_unknown(self):
"""for an unknown arch, we should get back that with arch 'default'."""