Kaydet (Commit) a78cccb1 authored tarafından Antoine Pitrou's avatar Antoine Pitrou

test_gdb: skip pretty-printing of sets with gdb < 7.3

(should fix the failures on OpenIndiana)
üst d0f3e07a
...@@ -309,6 +309,8 @@ class PrettyPrintTests(DebuggerTests): ...@@ -309,6 +309,8 @@ class PrettyPrintTests(DebuggerTests):
def test_sets(self): def test_sets(self):
'Verify the pretty-printing of sets' 'Verify the pretty-printing of sets'
if (gdb_major_version, gdb_minor_version) < (7, 3):
self.skipTest("pretty-printing of sets needs gdb 7.3 or later")
self.assertGdbRepr(set()) self.assertGdbRepr(set())
self.assertGdbRepr(set(['a', 'b']), "{'a', 'b'}") self.assertGdbRepr(set(['a', 'b']), "{'a', 'b'}")
self.assertGdbRepr(set([4, 5, 6]), "{4, 5, 6}") self.assertGdbRepr(set([4, 5, 6]), "{4, 5, 6}")
...@@ -322,6 +324,8 @@ id(s)''') ...@@ -322,6 +324,8 @@ id(s)''')
def test_frozensets(self): def test_frozensets(self):
'Verify the pretty-printing of frozensets' 'Verify the pretty-printing of frozensets'
if (gdb_major_version, gdb_minor_version) < (7, 3):
self.skipTest("pretty-printing of frozensets needs gdb 7.3 or later")
self.assertGdbRepr(frozenset()) self.assertGdbRepr(frozenset())
self.assertGdbRepr(frozenset(['a', 'b']), "frozenset({'a', 'b'})") self.assertGdbRepr(frozenset(['a', 'b']), "frozenset({'a', 'b'})")
self.assertGdbRepr(frozenset([4, 5, 6]), "frozenset({4, 5, 6})") self.assertGdbRepr(frozenset([4, 5, 6]), "frozenset({4, 5, 6})")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment