diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-08-02 12:47:50 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-08-02 12:47:50 +0000 |
commit | 0c4addea3407c6268cd01be51e8d56a804e5b15d (patch) | |
tree | 6a632c6d718df3fdad70db4b8a3569a58f595176 /pw/tests/pw_groupdel.sh | |
parent | f1bef959a51e2994216735586c6ef525f2728f10 (diff) | |
download | pw-darwin-0c4addea3407c6268cd01be51e8d56a804e5b15d.tar.gz pw-darwin-0c4addea3407c6268cd01be51e8d56a804e5b15d.tar.zst pw-darwin-0c4addea3407c6268cd01be51e8d56a804e5b15d.zip |
Rewrite parsing subcommands arguments of pw(8)
Now each subcommands checks its arguments in a dedicated functions.
This helps improving input validation, code readability/maintainability
While here:
- Add a -y option to pw userdel/usermod so it can maintain NIS servers if
nispasswd is not defined in pw.conf(5)
- Allow pw -r <rootdir> to remove directory with userdel -r
- Fix bug when renaming a user which was not renaming the user name it groups
it is a member of.
- Only parse pw.conf(5) when needed.
Diffstat (limited to 'pw/tests/pw_groupdel.sh')
-rwxr-xr-x | pw/tests/pw_groupdel.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pw/tests/pw_groupdel.sh b/pw/tests/pw_groupdel.sh index 75b063a..88cc0e0 100755 --- a/pw/tests/pw_groupdel.sh +++ b/pw/tests/pw_groupdel.sh @@ -13,7 +13,7 @@ group_do_not_delete_wheel_if_group_unknown_head() { group_do_not_delete_wheel_if_group_unknown_body() { populate_etc_skel atf_check -s exit:0 -o inline:"wheel:*:0:root\n" -x ${PW} groupshow wheel - atf_check -e inline:"pw: -g expects a number\n" -s exit:64 -x \ + atf_check -e inline:"pw: Bad id 'I_do_not_exist': invalid\n" -s exit:64 -x \ ${PW} groupdel -g I_do_not_exist atf_check -s exit:0 -o inline:"wheel:*:0:root\n" -x ${PW} groupshow wheel } |