Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / native_client / tests / gdb / call_from_gdb.py
index 4b32ca3..6d7ae53 100644 (file)
@@ -3,16 +3,17 @@
 # Use of this source code is governed by a BSD-style license that can be
 # found in the LICENSE file.
 
-from gdb_test import AssertEquals
 import gdb_test
 
 
-def test(gdb):
-  gdb.Command('break main')
-  gdb.ResumeAndExpectStop('continue', 'breakpoint-hit')
-  AssertEquals(gdb.Eval('test_call_from_gdb(1)'), '3')
-  AssertEquals(gdb.Eval('global_var'), '2')
+class CallFromGdbTest(gdb_test.GdbTest):
+
+  def test_call_from_gdb_test(self):
+    self.gdb.Command('break main')
+    self.gdb.ResumeAndExpectStop('continue', 'breakpoint-hit')
+    self.assertEquals(self.gdb.Eval('test_call_from_gdb(1)'), '3')
+    self.assertEquals(self.gdb.Eval('global_var'), '2')
 
 
 if __name__ == '__main__':
-  gdb_test.RunTest(test, 'call_from_gdb')
+  gdb_test.Main()