FreeBSD Bugzilla – Attachment 150409 Details for
Bug 195832
[patch] Additional add user tests for /usr/sbin/pw
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
pw_add.diff (text/plain), 2.01 KB, created by
oneil.rs
on 2014-12-09 20:30:05 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
oneil.rs
Created:
2014-12-09 20:30:05 UTC
Size:
2.01 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 274783) >+++ Makefile (working copy) >@@ -5,8 +5,9 @@ > > TESTSDIR= ${TESTSBASE}/usr.sbin/pw > >-ATF_TESTS_SH= pw_delete pw_lock pw_modify pw_etcdir >+ATF_TESTS_SH= pw_add pw_delete pw_lock pw_modify pw_etcdir > >+TEST_METADATA.pw_add+= required_user="root" > TEST_METADATA.pw_delete+= required_user="root" > TEST_METADATA.pw_modify+= required_user="root" > >Index: pw_add.sh >=================================================================== >--- pw_add.sh (revision 0) >+++ pw_add.sh (working copy) >@@ -0,0 +1,40 @@ >+# $FreeBSD$ >+ >+# Import helper functions >+. $(atf_get_srcdir)/helper_functions.shin >+ >+# Test add user >+atf_test_case user_add >+user_add_body() { >+ populate_etc_skel >+ >+ atf_check -s exit:0 ${PW} useradd test >+ atf_check -s exit:0 -o match:"^test:.*" \ >+ grep "^test:.*" $HOME/master.passwd >+} >+ >+ >+atf_test_case user_add_comments >+user_add_comments_body() { >+ populate_etc_skel >+ >+ atf_check -s exit:0 ${PW} useradd test -c "Test User,work,123,456" >+ atf_check -s exit:0 -o match:"^test:.*:Test User,work,123,456:" \ >+ grep "^test:.*:Test User,work,123,456:" $HOME/master.passwd >+} >+ >+atf_test_case user_add_comments_invalid >+user_add_comments_invalid_body() { >+ populate_etc_skel >+ >+ atf_check -s exit:65 -e match:"invalid character" \ >+ ${PW} useradd test -c "Test User,work,123:456,456" >+ atf_check -s exit:1 -o empty \ >+ grep "^test:.*:Test User,work,123:456,456:" $HOME/master.passwd >+} >+ >+atf_init_test_cases() { >+ atf_add_test_case user_add >+ atf_add_test_case user_add_comments >+ atf_add_test_case user_add_comments_invalid >+} > >Property changes on: pw_add.sh >___________________________________________________________________ >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Added: svn:keywords >## -0,0 +1 ## >+FreeBSD=%H >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:executable >## -0,0 +1 ## >+* >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 195832
: 150409