summaryrefslogtreecommitdiff
path: root/tests/cloud_tests/testcases/modules
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cloud_tests/testcases/modules')
-rw-r--r--tests/cloud_tests/testcases/modules/set_password_list.py20
-rw-r--r--tests/cloud_tests/testcases/modules/set_password_list_string.py11
2 files changed, 14 insertions, 17 deletions
diff --git a/tests/cloud_tests/testcases/modules/set_password_list.py b/tests/cloud_tests/testcases/modules/set_password_list.py
index b764362f..6819d259 100644
--- a/tests/cloud_tests/testcases/modules/set_password_list.py
+++ b/tests/cloud_tests/testcases/modules/set_password_list.py
@@ -4,22 +4,8 @@
from tests.cloud_tests.testcases import base
-class TestPasswordList(base.CloudTestCase):
- """Test password module"""
-
- # TODO: Verify dick and harry passwords are random
- # TODO: Verify tom's password was changed
-
- def test_shadow(self):
- """Test every tom, dick, and harry user in shadow"""
- out = self.get_data_file('shadow')
- self.assertIn('tom:', out)
- self.assertIn('dick:', out)
- self.assertIn('harry:', out)
-
- def test_sshd_config(self):
- """Test sshd config allows passwords"""
- out = self.get_data_file('sshd_config')
- self.assertIn('PasswordAuthentication yes', out)
+class TestPasswordList(base.PasswordListTest, base.CloudTestCase):
+ """Test password setting via list in chpasswd/list"""
+ __test__ = True
# vi: ts=4 expandtab
diff --git a/tests/cloud_tests/testcases/modules/set_password_list_string.py b/tests/cloud_tests/testcases/modules/set_password_list_string.py
new file mode 100644
index 00000000..2c34fada
--- /dev/null
+++ b/tests/cloud_tests/testcases/modules/set_password_list_string.py
@@ -0,0 +1,11 @@
+# This file is part of cloud-init. See LICENSE file for license information.
+
+"""cloud-init Integration Test Verify Script"""
+from tests.cloud_tests.testcases import base
+
+
+class TestPasswordListString(base.PasswordListTest, base.CloudTestCase):
+ """Test password setting via string in chpasswd/list"""
+ __test__ = True
+
+# vi: ts=4 expandtab