Back to index

python3.2  3.2.2
Classes | Functions | Variables
test.test_gdb Namespace Reference

Classes

class  DebuggerTests
class  PrettyPrintTests
class  PyListTests
class  StackNavigationTests
class  PyBtTests
class  PyPrintTests
class  PyLocalsTests

Functions

def gdb_has_frame_select
def test_main

Variables

tuple stdout = subprocess.PIPE).communicate()
tuple gdb_version_number = re.search(b"^GNU gdb [^\d]*(\d+)\.", gdb_version)
string cmd = "--eval-command=python import sys; print sys.version_info"
tuple p
tuple HAS_PYUP_PYDOWN = gdb_has_frame_select()
string BREAKPOINT_FN = 'builtin_id'

Function Documentation

Definition at line 35 of file test_gdb.py.

00035 
00036 def gdb_has_frame_select():
00037     # Does this build of gdb have gdb.Frame.select ?
00038     cmd = "--eval-command=python print(dir(gdb.Frame))"
00039     p = subprocess.Popen(["gdb", "--batch", cmd],
00040                          stdout=subprocess.PIPE)
00041     stdout, _ = p.communicate()
00042     m = re.match(br'.*\[(.*)\].*', stdout)
00043     if not m:
00044         raise unittest.SkipTest("Unable to parse output from gdb.Frame.select test")
00045     gdb_frame_dir = m.group(1).split(b', ')
00046     return b"'select'" in gdb_frame_dir

Here is the call graph for this function:

Definition at line 686 of file test_gdb.py.

00686 
00687 def test_main():
00688     if python_is_optimized():
00689         raise unittest.SkipTest("Python was compiled with optimizations")
00690     run_unittest(PrettyPrintTests,
00691                  PyListTests,
00692                  StackNavigationTests,
00693                  PyBtTests,
00694                  PyPrintTests,
00695                  PyLocalsTests
00696                  )

Here is the call graph for this function:


Variable Documentation

Definition at line 49 of file test_gdb.py.

string test.test_gdb.cmd = "--eval-command=python import sys; print sys.version_info"

Definition at line 28 of file test_gdb.py.

tuple test.test_gdb.gdb_version_number = re.search(b"^GNU gdb [^\d]*(\d+)\.", gdb_version)

Definition at line 22 of file test_gdb.py.

Definition at line 47 of file test_gdb.py.

Initial value:
00001 subprocess.Popen(["gdb", "--batch", cmd],
00002                      stdout=subprocess.PIPE)

Definition at line 29 of file test_gdb.py.

tuple test.test_gdb.stdout = subprocess.PIPE).communicate()

Definition at line 17 of file test_gdb.py.