class TestConstWithData4IsntLocation(unittest.TestCase):
def _test_file(self, filename):
filepath = os.path.join('test', 'testfiles_for_unittests', filename)
- print('Reading %s...' % (filename))
with open(filepath, 'rb') as f:
elffile = ELFFile(f)
dwarfinfo = elffile.get_dwarf_info()
locparser = LocationParser(dwarfinfo.location_lists())
for CU in dwarfinfo.iter_CUs():
- print("Compile unit %s..." % CU.get_top_DIE().attributes['DW_AT_name'].value.decode('utf-8'))
ver = CU['version']
for DIE in CU.iter_DIEs():
for key in DIE.attributes:
self._test_file('pascalenum.o')
if __name__ == '__main__':
- unittest.main()
+ unittest.main()
class TestGNUCallAttributesHaveLocation(unittest.TestCase):
def _test_file(self, filename):
filepath = os.path.join('test', 'testfiles_for_unittests', filename)
- print('Reading %s...' % (filename))
with open(filepath, 'rb') as f:
elffile = ELFFile(f)
dwarfinfo = elffile.get_dwarf_info()
for CU in dwarfinfo.iter_CUs():
ver = CU['version']
- print("Compile unit %s..." % CU.get_top_DIE().attributes['DW_AT_name'].value.decode('utf-8'))
-
for DIE in CU.iter_DIEs():
for key in DIE.attributes:
attr = DIE.attributes[key]
self._test_file('dwarf_gnuops1.o')
if __name__ == '__main__':
- unittest.main()
\ No newline at end of file
+ unittest.main()