2 # Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
9 class PrintSymbolTest(gdb_test.GdbTest):
11 def test_print_symbol(self):
12 self.gdb.Command('break set_global_var')
13 self.gdb.ResumeAndExpectStop('continue', 'breakpoint-hit')
14 self.assertEquals(self.gdb.Eval('global_var'), '2')
15 self.assertEquals(self.gdb.Eval('arg'), '1')
16 self.gdb.ResumeAndExpectStop('finish', 'function-finished')
17 self.assertEquals(self.gdb.Eval('global_var'), '1')
18 self.assertEquals(self.gdb.Eval('local_var'), '3')
21 if __name__ == '__main__':