use the stricter PyMapping_Check (closes #15801)

This commit is contained in:
Benjamin Peterson 2012-08-28 17:55:35 -04:00
parent 2412c93a60
commit 28a6cfaefc
3 changed files with 7 additions and 2 deletions

View file

@ -1142,6 +1142,9 @@ def test_formatting(self):
self.checkraises(TypeError, '%10.*f', '__mod__', ('foo', 42.))
self.checkraises(ValueError, '%10', '__mod__', (42,))
class X(object): pass
self.checkraises(TypeError, 'abc', '__mod__', X())
def test_floatformatting(self):
# float formatting
for prec in range(100):