From 595d4f2ac3d8cae06b6de958f152519b2c65276b Mon Sep 17 00:00:00 2001 From: rallytime Date: Wed, 8 Jun 2016 12:42:52 -0600 Subject: [PATCH] Fixup new groupadd tests for syntax change in 2016.3 --- tests/unit/modules/groupadd_test.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/unit/modules/groupadd_test.py b/tests/unit/modules/groupadd_test.py index c0c0a748dbb5..30a5e2d4e686 100644 --- a/tests/unit/modules/groupadd_test.py +++ b/tests/unit/modules/groupadd_test.py @@ -114,16 +114,16 @@ def test_adduser(self): ''' os_version_list = [ {'grains': {'kernel': 'Linux', 'os_family': 'RedHat', 'osmajorrelease': '5'}, - 'cmd': 'gpasswd -a root test'}, + 'cmd': ('gpasswd', '-a', 'root', 'test')}, {'grains': {'kernel': 'Linux', 'os_family': 'Suse', 'osrelease_info': [11, 2]}, - 'cmd': 'usermod -A test root'}, + 'cmd': ('usermod', '-A', 'test', 'root')}, {'grains': {'kernel': 'Linux'}, - 'cmd': 'gpasswd --add root test'}, + 'cmd': ('gpasswd', '--add', 'root', 'test')}, {'grains': {'kernel': 'OTHERKERNEL'}, - 'cmd': 'usermod -G test root'}, + 'cmd': ('usermod', '-G', 'test', 'root')}, ] for os_version in os_version_list: @@ -141,13 +141,13 @@ def test_deluser(self): ''' os_version_list = [ {'grains': {'kernel': 'Linux', 'os_family': 'RedHat', 'osmajorrelease': '5'}, - 'cmd': 'gpasswd -d root test'}, + 'cmd': ('gpasswd', '-d', 'root', 'test')}, {'grains': {'kernel': 'Linux', 'os_family': 'Suse', 'osrelease_info': [11, 2]}, - 'cmd': 'usermod -R test root'}, + 'cmd': ('usermod', '-R', 'test', 'root')}, {'grains': {'kernel': 'Linux'}, - 'cmd': 'gpasswd --del root test'}, + 'cmd': ('gpasswd', '--del', 'root', 'test')}, {'grains': {'kernel': 'OpenBSD'}, 'cmd': 'usermod -S foo root'}, @@ -176,13 +176,13 @@ def test_members(self): ''' os_version_list = [ {'grains': {'kernel': 'Linux', 'os_family': 'RedHat', 'osmajorrelease': '5'}, - 'cmd': "gpasswd -M foo test"}, + 'cmd': ('gpasswd', '-M', 'foo', 'test')}, {'grains': {'kernel': 'Linux', 'os_family': 'Suse', 'osrelease_info': [11, 2]}, - 'cmd': 'groupmod -A foo test'}, + 'cmd': ('groupmod', '-A', 'foo', 'test')}, {'grains': {'kernel': 'Linux'}, - 'cmd': 'gpasswd --members foo test'}, + 'cmd': ('gpasswd', '--members', 'foo', 'test')}, {'grains': {'kernel': 'OpenBSD'}, 'cmd': 'usermod -G test foo'},