本文整理匯總了Python中collector.Collector.parse_size_line方法的典型用法代碼示例。如果您正苦於以下問題:Python Collector.parse_size_line方法的具體用法?Python Collector.parse_size_line怎麽用?Python Collector.parse_size_line使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類collector.Collector
的用法示例。
在下文中一共展示了Collector.parse_size_line方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: test_ignores_incomplete_size_line_2
# 需要導入模塊: from collector import Collector [as 別名]
# 或者: from collector.Collector import parse_size_line [as 別名]
def test_ignores_incomplete_size_line_2(self):
c = Collector()
line = "U __preinit_array_end"
self.assertFalse(c.parse_size_line(line))
self.assertDictEqual(c.symbols, {})
示例2: test_ignores_incomplete_size_line_1
# 需要導入模塊: from collector import Collector [as 別名]
# 或者: from collector.Collector import parse_size_line [as 別名]
def test_ignores_incomplete_size_line_1(self):
c = Collector()
line = "0000059c D __dso_handle"
self.assertFalse(c.parse_size_line(line))
self.assertDictEqual(c.symbols, {})
示例3: test_parses_variable_line_from_initialized_data_section
# 需要導入模塊: from collector import Collector [as 別名]
# 或者: from collector.Collector import parse_size_line [as 別名]
def test_parses_variable_line_from_initialized_data_section(self):
c = Collector()
line = "00000968 000000c8 D foo /Users/behrens/Documents/projects/pebble/puncover/pebble/build/puncover.c:15"
self.assertTrue(c.parse_size_line(line))
self.assertDictEqual(c.symbols, {0x00000968: {'name': 'foo', 'base_file': 'puncover.c', 'path': '/Users/behrens/Documents/projects/pebble/puncover/pebble/build/puncover.c', 'address': '00000968', 'line': 15, 'size': 200, 'type': 'variable'}})
示例4: test_parses_variable_line_from_uninitialized_data_section
# 需要導入模塊: from collector import Collector [as 別名]
# 或者: from collector.Collector import parse_size_line [as 別名]
def test_parses_variable_line_from_uninitialized_data_section(self):
c = Collector()
line = "00000a38 00000008 b some_double_value /Users/behrens/Documents/projects/pebble/puncover/pebble/build/../src/puncover.c:17"
self.assertTrue(c.parse_size_line(line))
self.assertDictEqual(c.symbols, {0x00000a38: {'name': 'some_double_value', 'base_file': 'puncover.c', 'path': '/Users/behrens/Documents/projects/pebble/puncover/pebble/build/../src/puncover.c', 'address': '00000a38', 'line': 17, 'size': 8, 'type': 'variable'}})
示例5: test_parses_function_line
# 需要導入模塊: from collector import Collector [as 別名]
# 或者: from collector.Collector import parse_size_line [as 別名]
def test_parses_function_line(self):
c = Collector()
line = "00000550 00000034 T main /Users/behrens/Documents/projects/pebble/puncover/puncover/build/../src/puncover.c:25"
self.assertTrue(c.parse_size_line(line))
self.assertDictEqual(c.symbols, {0x00000550: {'name': 'main', 'base_file': 'puncover.c', 'path': '/Users/behrens/Documents/projects/pebble/puncover/puncover/build/../src/puncover.c', 'address': '00000550', 'line': 25, 'size': 52, 'type': 'function'}})