Lines Matching refs:assertGdbRepr
300 def assertGdbRepr(self, val, exp_repr=None): member in PrettyPrintTests
312 self.assertGdbRepr(42)
313 self.assertGdbRepr(0)
314 self.assertGdbRepr(-7)
315 self.assertGdbRepr(1000000000000)
316 self.assertGdbRepr(-1000000000000000)
320 self.assertGdbRepr(True)
321 self.assertGdbRepr(False)
322 self.assertGdbRepr(None)
326 self.assertGdbRepr({})
327 self.assertGdbRepr({'foo': 'bar'}, "{'foo': 'bar'}")
329 self.assertGdbRepr({'foo': 'bar', 'douglas': 42}, "{'foo': 'bar', 'douglas': 42}")
333 self.assertGdbRepr([])
334 self.assertGdbRepr(list(range(5)))
338 self.assertGdbRepr(b'')
339 self.assertGdbRepr(b'And now for something hopefully the same')
340 self.assertGdbRepr(b'string with embedded NUL here \0 and then some more text')
341 self.assertGdbRepr(b'this is a tab:\t'
346 self.assertGdbRepr(b'this is byte 255:\xff and byte 128:\x80')
348 self.assertGdbRepr(bytes([b for b in range(255)]))
371 self.assertGdbRepr(text, ascii(text))
373 self.assertGdbRepr(text)
375 self.assertGdbRepr('')
376 self.assertGdbRepr('And now for something hopefully the same')
377 self.assertGdbRepr('string with embedded NUL here \0 and then some more text')
397 self.assertGdbRepr(tuple(), '()')
398 self.assertGdbRepr((1,), '(1,)')
399 self.assertGdbRepr(('foo', 'bar', 'baz'))
405 self.assertGdbRepr(set(), "set()")
406 self.assertGdbRepr(set(['a']), "{'a'}")
409 self.assertGdbRepr(set(['a', 'b']), "{'a', 'b'}")
410 self.assertGdbRepr(set([4, 5, 6]), "{4, 5, 6}")
423 self.assertGdbRepr(frozenset(), "frozenset()")
424 self.assertGdbRepr(frozenset(['a']), "frozenset({'a'})")
427 self.assertGdbRepr(frozenset(['a', 'b']), "frozenset({'a', 'b'})")
428 self.assertGdbRepr(frozenset([4, 5, 6]), "frozenset({4, 5, 6})")