Changeset 2725 in MondoRescue for branches/2.2.9/mindi-busybox/testsuite/taskset.tests
- Timestamp:
- Feb 25, 2011, 9:26:54 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2.9/mindi-busybox/testsuite/taskset.tests
r1765 r2725 1 1 #!/bin/sh 2 # Copyright 2006 Bernhard Reutner-Fischer 3 # Licensed under GPLv2 or later, see file LICENSE in this source tree. 2 4 3 # Copyright 2006 Bernhard Fischer 4 # Licensed under GPL v2 or later, see file LICENSE for details. 5 6 . testing.sh 5 . ./testing.sh 7 6 a="taskset" 8 7 9 8 # testing "test name" "opts" "expected result" "file inp" "stdin" 10 testing "taskset (get from pid 1)" "$a -p 1 >/dev/null;echo \$?" "0\n" "" ""11 testing "taskset (invalid pid)" "$a -p 0 >/dev/null 2>&1;echo \$?" "1\n" "" ""9 testing "taskset (get from pid 1)" "$a -p 1 >/dev/null;echo \$?" "0\n" "" "" 10 testing "taskset (invalid pid)" "$a -p 0 >/dev/null 2>&1;echo \$?" "1\n" "" "" 12 11 testing "taskset (set_aff, needs CAP_SYS_NICE)" \ 13 "$a 0x1 $SHELL -c $a\ -p\ \$$\|grep\ \"current\ affinity\ mask:\ 1\" >/dev/null;echo \$?" \14 12 "$a 0x1 $SHELL -c '$a -p \$\$ | grep \"current affinity mask: 1\" >/dev/null'; echo \$?" \ 13 "0\n" "" "" 15 14 16 15 unset a
Note:
See TracChangeset
for help on using the changeset viewer.