From bbbeff33745b038e50a809eeb3b08b8f73b6cff5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Zachar?= Date: Mon, 5 Aug 2024 11:50:47 +0200 Subject: [PATCH] Improve checking for systemtap files Log whether _STAP_FILE (the systemtap example) is used from any rpm. Make sure the tapset (probes files) is used from PACKAGES --- systemtap-static-probes-in-ruby/runtest.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/systemtap-static-probes-in-ruby/runtest.sh b/systemtap-static-probes-in-ruby/runtest.sh index 312e713..cfac459 100755 --- a/systemtap-static-probes-in-ruby/runtest.sh +++ b/systemtap-static-probes-in-ruby/runtest.sh @@ -44,6 +44,7 @@ rlJournalStart rlAssertRpm --all rlAssertBinaryOrigin $RUBY rlAssertExists "${_STAP_FILE}" || rlDie + rlLog "Using STAP_FILE from $(rpm -qf ${_STAP_FILE})." rlRun "stap-prep" 0 "Prepare system for systemtap use" rlRun "TmpDir=\`mktemp -d\`" 0 "Creating tmp directory" rlRun "pushd ${TmpDir}" @@ -53,8 +54,7 @@ rlJournalStart rlPhaseStartTest # TODO: Systemtap - The test could be enlarged by other methods / functions / objects / ... - rlRun "rpm -ql $PACKAGES | grep 'stp' | grep 'tapset'" 0 "Checking tapset file" - rlRun "rpm -ql $PACKAGES | grep 'stp' | grep 'doc'" 0 "Checking doc file" + rlRun "rpm -ql $PACKAGES | grep 'stp' | grep 'tapset'" 0 "Checking file with ruby systemtap probes" if ! $RUBY $RUBY_OPTS -e ''; then rlLog "Can't use $RUBY_OPTS as option for $RUBY, removing these options"