Skip to content

Commit 2fedf44

Browse files
author
Kevin Frei
committed
Fixed the script to acquire the UUID without creating a target
1 parent a283b6d commit 2fedf44

File tree

2 files changed

+10
-18
lines changed

2 files changed

+10
-18
lines changed

lldb/test/API/debuginfod/Normal/TestDebuginfod.py

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,6 @@ class DebugInfodTests(TestBase):
2222
# No need to try every flavor of debug inf.
2323
NO_DEBUG_INFO_TESTCASE = True
2424

25-
# def setUp(self):
26-
# TestBase.setUp(self)
27-
# # Don't run these tests if we don't have Debuginfod support
28-
# if "Debuginfod" not in configuration.enabled_plugins:
29-
# self.skipTest("The Debuginfod SymbolLocator plugin is not enabled")
30-
3125
def test_normal_no_symbols(self):
3226
"""
3327
Validate behavior with no symbols or symbol locator.
@@ -178,8 +172,10 @@ def config_test(self, local_files, debuginfo=None, executable=None):
178172
def getUUID(self, filename):
179173
try:
180174
spec = lldb.SBModuleSpec()
181-
spec.SetFileSpec(self.getBuildArtifact(filename))
182-
uuid = lldb.SBModule(spec).GetUUIDString().replace("-", "").lower()
183-
return uuid if len(uuid) > 8 else None # Shouldn't have CRC's in this field
175+
spec.SetFileSpec(lldb.SBFileSpec(self.getBuildArtifact(filename)))
176+
module = lldb.SBModule(spec)
177+
uuid = module.GetUUIDString().replace("-", "").lower()
178+
# Don't want lldb's fake 32 bit CRC's for this one
179+
return uuid if len(uuid) > 8 else None
184180
except:
185181
return None

lldb/test/API/debuginfod/SplitDWARF/TestDebuginfodDWP.py

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,6 @@ class DebugInfodDWPTests(TestBase):
2525
# No need to try every flavor of debug inf.
2626
NO_DEBUG_INFO_TESTCASE = True
2727

28-
# def setUp(self):
29-
# TestBase.setUp(self)
30-
# # Don't run these tests if we don't have Debuginfod support
31-
# if "Debuginfod" not in configuration.enabled_plugins:
32-
# self.skipTest("The Debuginfod SymbolLocator plugin is not enabled")
33-
3428
def test_normal_stripped(self):
3529
"""
3630
Validate behavior with a stripped binary, no symbols or symbol locator.
@@ -187,8 +181,10 @@ def config_test(self, local_files, debuginfo=None, executable=None):
187181
def getUUID(self, filename):
188182
try:
189183
spec = lldb.SBModuleSpec()
190-
spec.SetFileSpec(self.getBuildArtifact(filename))
191-
uuid = lldb.SBModule(spec).GetUUIDString().replace("-", "").lower()
192-
return uuid if len(uuid) > 8 else None # Shouldn't have CRC's in this field
184+
spec.SetFileSpec(lldb.SBFileSpec(self.getBuildArtifact(filename)))
185+
module = lldb.SBModule(spec)
186+
uuid = module.GetUUIDString().replace("-", "").lower()
187+
# Don't want lldb's fake 32 bit CRC's for this one
188+
return uuid if len(uuid) > 8 else None
193189
except:
194190
return None

0 commit comments

Comments
 (0)