Skip to content

Commit

Permalink
Merge pull request #2779 from misanjumn/trace-fedora-support
Browse files Browse the repository at this point in the history
trace: Add Fedora Support to trace testing
  • Loading branch information
PraveenPenguin authored Mar 27, 2024
2 parents 97b2b70 + 57150b4 commit dd7d9b7
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
7 changes: 7 additions & 0 deletions trace/dawr.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ def test_read_dawr_v1(self):
executing the program
"""
child, return_value = self.run_cmd('dawr_v1')
i = 0
if self.distro_name == "fedora":
child.sendline('set debuginfod enabled on')
child.expect_exact([pexpect.TIMEOUT, ''])
child.sendline('awatch a')
return_value.append(child.expect_exact(['watchpoint 1: a',
pexpect.TIMEOUT]))
Expand All @@ -88,6 +92,9 @@ def test_read_dawr_v2(self):
"""
child, return_value = self.run_cmd('dawr_v2')
i = 0
if self.distro_name == "fedora":
child.sendline('set debuginfod enabled on')
child.expect_exact([pexpect.TIMEOUT, ''])
for value in ['a', 'b']:
i = i+1
child.sendline('awatch %s' % value)
Expand Down
3 changes: 2 additions & 1 deletion trace/perf_uprobe.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ def test_uprobe_return(self):
if (self.distro_name == "rhel" and self.detected_distro.version > "7")\
or (self.distro_name == "SuSE" and
self.detected_distro.version >= 15 and
self.detected_distro.release >= 2):
self.detected_distro.release >= 2)\
or (self.distro_name == "fedora"):
output = self.cmd_verify('%s__return -- ./uprobe_test'
% self.recProbe)
else:
Expand Down
2 changes: 1 addition & 1 deletion trace/trace_UDT_probes.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def setUp(self):
if 'Ubuntu' in self.distro_name:
deps.extend(['linux-tools-common', 'linux-tools-%s' %
platform.uname()[2]])
elif self.distro_name in ['rhel', 'SuSE']:
elif self.distro_name in ['rhel', 'SuSE', 'fedora', 'centos']:
deps.extend(['perf', 'systemtap-sdt-devel.ppc64le'])
else:
self.cancel("Install the package for perf supported\
Expand Down

0 comments on commit dd7d9b7

Please sign in to comment.