testsuite/systemtap.interactive/input.char.exp
raw| 1 | set test "input.char" |
| 2 | if {! [installtest_p]} { untested "$test"; return } |
| 3 | set send_human { .1 .3 1 .05 2 } |
| 4 | |
| 5 | catch { |
| 6 | spawn stap $srcdir/$subdir/$test.stp |
| 7 | expect |
| 8 | |
| 9 | send -raw "abcde" |
| 10 | |
| 11 | expect { |
| 12 | "a\r\nb\r\nc\r\nzze\r\n" { pass "sub1" } |
| 13 | timeout { fail "sub1" } |
| 14 | } |
| 15 | |
| 16 | send -h -raw "12345\n" |
| 17 | |
| 18 | expect { |
| 19 | "1\r\n2\r\n3\r\n4\r\n5\r\n\r\n" { pass "sub2" } |
| 20 | timeout { fail "sub2" } |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | kill -INT -[exp_pid] 3 |
| 25 | catch {close}; catch {wait} |