| 1 |
# Check that globals, functions, and aliases will pull in probes from the |
| 2 |
# tapset file in which they are defined. |
| 3 |
|
| 4 |
if {![installtest_p]} { untested "tapset includes"; return } |
| 5 |
|
| 6 |
set tapset "$srcdir/$subdir/tapset" |
| 7 |
|
| 8 |
# global |
| 9 |
set script "probe end { if (test_global) println(\"end\") }" |
| 10 |
set ::result_string "included global\nend" |
| 11 |
stap_run_exact "tapset include global" -I$tapset -e $script -c true |
| 12 |
|
| 13 |
# function |
| 14 |
set script "probe end { if (test_function()) println(\"end\") }" |
| 15 |
set ::result_string "included function\nend" |
| 16 |
stap_run_exact "tapset include function" -I$tapset -e $script -c true |
| 17 |
|
| 18 |
# alias |
| 19 |
set script "probe test_alias { if (alias_local) println(\"end\") }" |
| 20 |
set ::result_string "included alias\nend" |
| 21 |
stap_run_exact "tapset include alias" -I$tapset -e $script -c true |