📄 test_policy.sh
字号:
#!/bin/sh## $XORP: xorp/policy/test/test_policy.sh,v 1.3 2006/04/26 03:26:29 pavlin Exp $#TMPFILE=/tmp/xorp_policy_test.txtcleanup() { rm -f ${TMPFILE}}if [ $# -ne "4" ]then echo "Usage: `basename $0` policyfile policy_var_map_file varfile exitcode" exit 1fiecho Will run policy $1 with policy_var_map_file $2 with variables $3 checking for exit code $4./compilepolicy -s $1 -m $2 -o ${TMPFILE}if [ $? -ne 0 ] ; then exit 1ficat ${TMPFILE}./execpolicy ${TMPFILE} $3EXITCODE=$?if [ ${EXITCODE} -ne $4 ]thencleanupecho Test FAILED exit code ${EXITCODE}exit 1ficleanupecho Test was SUCCESSFULLexit 0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -