OSSP CVS Repository

ossp - Check-in [2090]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2090
Date: 2002-Apr-22 14:49:26 (local)
2002-Apr-22 12:49:26 (UTC)
User:ms
Branch:
Comment: Rearranged test commands and added comments to option identifiers.
Tickets:
Inspections:
Files:
ossp-pkg/rc/rc_config.h      1.3 -> 1.4     30 inserted, 30 deleted
ossp-pkg/rc/rc_test.sh      1.8 -> 1.9     17 inserted, 15 deleted

ossp-pkg/rc/rc_config.h 1.3 -> 1.4

--- rc_config.h  2002/04/22 12:16:39     1.3
+++ rc_config.h  2002/04/22 12:49:26     1.4
@@ -31,36 +31,36 @@
 #define __OSSPRC_CONFIG_H__
 
 /* Available options and their values */
-#define RC_HEADVAL   0  /* Unused, as popt reserves 0 to return success */
-#define RC_USE_VAL   1
-#define RC_DBG_VAL   2
-#define RC_VER_VAL   3
-#define RC_EVL_VAL   4
-#define RC_HLP_VAL   5
-#define RC_INF_VAL   6
-#define RC_LBL_VAL   7
-#define RC_PRN_VAL   8
-#define RC_SIL_VAL   9
-#define RC_RAW_VAL  10
-#define RC_VRB_VAL  11
-#define RC_EXC_VAL  12
-#define RC_LOC_VAL  13
-#define RC_CNF_VAL  14
-#define RC_FNC_VAL  15
-#define RC_QRY_VAL  16
-#define RC_TMP_VAL  17
-#define RC_OWN_VAL  18
-#define RC_GRP_VAL  19
-#define RC_MSK_VAL  20
-#define RC_ASS_VAL  21
-#define RC_DEF_VAL  22
-#define RC_REF_VAL  23
-#define RC_PRM_VAL  24
-#define RC_TRM_VAL  25
-#define RC_NCF_VAL  26
-#define RC_CMN_VAL  27
-#define RC_DFL_VAL  28
-#define RC_ERR_VAL  29
+#define RC_HEADVAL   0  /* Unused         */
+#define RC_USE_VAL   1  /* Usage          */
+#define RC_DBG_VAL   2  /* Debug          */
+#define RC_VER_VAL   3  /* Version        */
+#define RC_EVL_VAL   4  /* Eval           */
+#define RC_HLP_VAL   5  /* Help           */
+#define RC_INF_VAL   6  /* Info           */
+#define RC_LBL_VAL   7  /* Label          */
+#define RC_PRN_VAL   8  /* Print          */
+#define RC_SIL_VAL   9  /* Silent         */
+#define RC_RAW_VAL  10  /* Raw            */
+#define RC_VRB_VAL  11  /* Verbose        */
+#define RC_EXC_VAL  12  /* Exec           */
+#define RC_LOC_VAL  13  /* Locations      */
+#define RC_CNF_VAL  14  /* Conf file      */
+#define RC_FNC_VAL  15  /* Func file      */
+#define RC_QRY_VAL  16  /* Format         */
+#define RC_TMP_VAL  17  /* Temp dir       */
+#define RC_OWN_VAL  18  /* User name      */
+#define RC_GRP_VAL  19  /* Group name     */
+#define RC_MSK_VAL  20  /* Umask          */
+#define RC_ASS_VAL  21  /* Assign regex   */
+#define RC_DEF_VAL  22  /* Label regex    */
+#define RC_REF_VAL  23  /* Ref regex      */
+#define RC_PRM_VAL  24  /* Params regex   */
+#define RC_TRM_VAL  25  /* Terminal regex */
+#define RC_NCF_VAL  26  /* Config name    */
+#define RC_CMN_VAL  27  /* Common name    */
+#define RC_DFL_VAL  28  /* Default name   */
+#define RC_ERR_VAL  29  /* Error name     */
 
 #define RC_NUMOPTS  30  /* Increment with each option addition */
 


ossp-pkg/rc/rc_test.sh 1.8 -> 1.9

--- rc_test.sh   2002/04/12 19:15:12     1.8
+++ rc_test.sh   2002/04/22 12:49:26     1.9
@@ -28,44 +28,46 @@
 #  test_rc.sh: Run-command processor test script
 
 # Test short options, should fail for false combination usage
-./rc -dVehilpsrvxLcfqt samba start sleep=2 restart
 echo "./rc -dVehilpsrvxLcfqt samba start sleep=2 restart"
+./rc -dVehilpsrvxLcfqt samba start sleep=2 restart
 
 # Test short options, should succeed
-./rc -derv -L /sfw/etc/rc.d/rc.%{RCFILE:s/^all$/*/} -c /sfw/etc/rc.conf -f /sfw/etc/rc.func -t /tmp openssh stop sleep=4 start daily minsize=2097152
 echo; echo "./rc -derv -L /sfw/etc/rc.d/rc.%{RCFILE:s/^all$/*/} -c /sfw/etc/rc.conf -f /sfw/etc/rc.func -t /tmp openssh stop sleep=4 start daily minsize=2097152"
+./rc -derv -L /sfw/etc/rc.d/rc.%{RCFILE:s/^all$/*/} -c /sfw/etc/rc.conf -f /sfw/etc/rc.func -t /tmp openssh stop sleep=4 start daily minsize=2097152
 
 # Test some long options, should fail for false combination usage
-./rc --verbose --silent uucp stop sleep=6 start
 echo; echo "./rc --verbose --silent uucp stop sleep=6 start"
-./rc --query --silent zebra bing bang
+./rc --verbose --silent uucp stop sleep=6 start
 echo; echo "./rc --query --silent zebra bing bang"
-./rc --conf /sfw/rc.conf --locate /sfw/etc/rc.d --query what to enter here
-echo; echo "./rc --conf /sfw/rc.conf --locate /sfw/etc/rc.d --query what to enter here"
+./rc --query --silent zebra bing bang
+echo; echo "./rc --conf /sfw/rc.conf --locate /etc/rc3.d:/sfw/etc/rc.d --query what to enter here"
+./rc --conf /sfw/rc.conf --locate /etc/rc3.d:/sfw/etc/rc.d --query what to enter here
 
 # Test minimal set of long options, should succeed
+echo; echo "./rc --debug --version rsyncd nothing matters but the version"
 ./rc --debug --version rsyncd nothing matters but the version
-echo; echo "./rc --conf /sfw/rc.conf --locate /sfw/etc/rc.d --query what to enter here"
+echo; echo "./rc --conf /sfw/rc.conf --locate /cw/etc/rc.d:/sfw/etc/rc.d:/etc/rc --query what to enter here"
+./rc --conf /sfw/rc.conf --locate /cw/etc/rc.d:/sfw/etc/rc.d:/etc/rc --query what to enter here
 
 # FIXME these cases are not handled yet by our configuration FIXME #
-#./rc --debug --version
 #echo; echo "./rc --debug --version"
-#./rc --debug --help
+#./rc --debug --version
 #echo; echo "./rc --debug --help"
-#./rc --debug --info --verbose
+#./rc --debug --help
 #echo; echo "./rc --debug --info --verbose"
-#./rc --conf /etc/rc.conf --debug --info --raw
+#./rc --debug --info --verbose
 #echo; echo "./rc --conf /etc/rc.conf --debug --info --raw"
-#./rc --conf /sfw/rc.conf --tmp /sfw/RPM/TMP --debug --labels rsyncd
+#./rc --conf /etc/rc.conf --debug --info --raw
 #echo; echo "./rc --conf /sfw/rc.conf --tmp /sfw/RPM/TMP --debug --labels rsyncd"
+#./rc --conf /sfw/rc.conf --tmp /sfw/RPM/TMP --debug --labels rsyncd
 # FIXME these cases are not handled yet by our configuration FIXME #
 
-./rc --func /sfw/etc/rc.func --print --verbose openssh stop sleep=4 start
 echo; echo "./rc --func /sfw/etc/rc.func --print --verbose openssh stop sleep=4 start"
-./rc --func /sfw/etc/rc.func --debug --eval uucp restart
+./rc --func /sfw/etc/rc.func --print --verbose openssh stop sleep=4 start
 echo; echo "./rc --func /sfw/etc/rc.func --debug --eval uucp restart"
-./rc --conf ./myrc --func /sfw/etc/rc.func --tmp /tmp --debug --silent --exec uucp start
+./rc --func /sfw/etc/rc.func --debug --eval uucp restart
 echo; echo "./rc --conf ./myrc --func /sfw/etc/rc.func --tmp /tmp --debug --silent --exec uucp start"
+./rc --conf ./myrc --func /sfw/etc/rc.func --tmp /tmp --debug --silent --exec uucp start
 
 # Next milestone
 #RequireOwner

CVSTrac 2.0.1