diff options
Diffstat (limited to 'testsuite/systemtap.base/kmodule.exp')
-rw-r--r-- | testsuite/systemtap.base/kmodule.exp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/testsuite/systemtap.base/kmodule.exp b/testsuite/systemtap.base/kmodule.exp new file mode 100644 index 00000000..05f464f8 --- /dev/null +++ b/testsuite/systemtap.base/kmodule.exp @@ -0,0 +1,22 @@ +# Simple function to test that systemtap can generate instument a module +# function, install it, and get some output. + +load_lib "stap_run.exp" + +set test "kmodule" + +proc kmodule_load {} { + # force the filesystem to be synced + if {[lindex [local_exec "sync" "" "" 100] 0] == 0} { + return 0 + } else { + return 1 + } +} + +# better have a count other than zero to show that probe fired +set output_string "count = \[0-9\]\[0-9\]*\r\n" + +#make sure have ext3 module loaded before trying this + +stap_run $srcdir/$subdir/$test.stp kmodule_load $output_string |