add testcases for regnotif and unregnotif
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@10188 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
233971b604
commit
9ca51c2d15
62
xCAT-test/autotest/testcase/regnotif/case0
Normal file
62
xCAT-test/autotest/testcase/regnotif/case0
Normal file
@ -0,0 +1,62 @@
|
||||
start:regnotif_null
|
||||
description:regnotif with no argument
|
||||
cmd:regnotif
|
||||
check:rc==0
|
||||
check:output=~Usage
|
||||
end
|
||||
|
||||
start:regnotif_o
|
||||
description:regnotif with normal argument
|
||||
cmd:echo "hello,world" > test.pm
|
||||
check:rc==0
|
||||
cmd:regnotif test.pm nodelist -o a,d
|
||||
check:rc==0
|
||||
cmd:tabdump notification
|
||||
check:rc==0
|
||||
check:output=~"test.pm","nodelist","a,d"
|
||||
cmd:unregnotif test.pm
|
||||
cmd:rm -f test.pm
|
||||
end
|
||||
|
||||
|
||||
start:regnotif_err
|
||||
description:regnotif with error arguments
|
||||
cmd:echo "hello,world" > test.pm
|
||||
check:rc==0
|
||||
cmd:regnotif test.pm -o a,d
|
||||
check:output=~Usage
|
||||
cmd:regnotif nodelist -o a,d
|
||||
check:output=~Usage
|
||||
cmd:regnotif nodelist
|
||||
check:output=~Usage
|
||||
cmd:rm -f test.pm
|
||||
end
|
||||
|
||||
|
||||
|
||||
start:regnotif_h
|
||||
description:regnotif -h and --help
|
||||
cmd:regnotif -h
|
||||
check:rc==0
|
||||
check:output=~Usage
|
||||
cmd:regnotif --help
|
||||
check:rc==0
|
||||
check:output=~Usage
|
||||
end
|
||||
|
||||
|
||||
start:regnotif_v
|
||||
description:regnotif -v and --version
|
||||
cmd:regnotif -v
|
||||
check:rc==0
|
||||
check:output=~Version|version
|
||||
cmd:regnotif --version
|
||||
check:rc==0
|
||||
check:output=~Version|version
|
||||
end
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
39
xCAT-test/autotest/testcase/unregnotif/case0
Normal file
39
xCAT-test/autotest/testcase/unregnotif/case0
Normal file
@ -0,0 +1,39 @@
|
||||
start:unregnotif_null
|
||||
description:unregnotif with no argument
|
||||
cmd:unregnotif
|
||||
check:output=~Usage
|
||||
end
|
||||
|
||||
|
||||
start:unregnotif_f
|
||||
description:unregnotif with a argument filename
|
||||
cmd:echo "hello" > test.pm
|
||||
check:rc==0
|
||||
cmd:regnotif test.pm nodelist -o a,d
|
||||
check:rc==0
|
||||
cmd:tabdump notification
|
||||
check:rc==0
|
||||
check:output=~"test.pm","nodelist","a,d"
|
||||
cmd:unregnotif test.pm
|
||||
check:rc==0
|
||||
cmd:tabdump notification
|
||||
check:output!~test.pm","nodelist","a,d"
|
||||
cmd:rm -f test.pm
|
||||
end
|
||||
|
||||
|
||||
start:unregnotif_h
|
||||
description:unregnotif -h and -help
|
||||
cmd:unregnotif -h
|
||||
check:output=~Usage
|
||||
cmd:unregnotif -help
|
||||
check:output=~Usage
|
||||
end
|
||||
|
||||
start:unregnotif_v
|
||||
description:unregnotif -v and -version
|
||||
cmd:unregnotif -v
|
||||
check:output=~version|Version
|
||||
cmd:unregnotif -version
|
||||
check:output=~version|Version
|
||||
end
|
Loading…
Reference in New Issue
Block a user