diff options
author | Ethan Furman <ethan@stoneleaf.us> | 2014-03-19 15:38:52 (GMT) |
---|---|---|
committer | Ethan Furman <ethan@stoneleaf.us> | 2014-03-19 15:38:52 (GMT) |
commit | 38d872ee5df1dd89c1ce1e04e7e24ef651d63bc7 (patch) | |
tree | a9db03447bf5b874da900128d722be11a7908ab4 /Lib/test/string_tests.py | |
parent | 8e5d0caf923ba027f21a2a0953a365bc6174d492 (diff) | |
download | cpython-38d872ee5df1dd89c1ce1e04e7e24ef651d63bc7.zip cpython-38d872ee5df1dd89c1ce1e04e7e24ef651d63bc7.tar.gz cpython-38d872ee5df1dd89c1ce1e04e7e24ef651d63bc7.tar.bz2 |
Issue19995: passing a non-int to %o, %c, %x, or %X now raises an exception
Diffstat (limited to 'Lib/test/string_tests.py')
-rw-r--r-- | Lib/test/string_tests.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/test/string_tests.py b/Lib/test/string_tests.py index 5ed01f2..569bae1 100644 --- a/Lib/test/string_tests.py +++ b/Lib/test/string_tests.py @@ -1178,8 +1178,7 @@ class MixinStrUnicodeUserStringTest: self.checkraises(TypeError, 'abc', '__mod__') self.checkraises(TypeError, '%(foo)s', '__mod__', 42) self.checkraises(TypeError, '%s%s', '__mod__', (42,)) - with self.assertWarns(DeprecationWarning): - self.checkraises(TypeError, '%c', '__mod__', (None,)) + self.checkraises(TypeError, '%c', '__mod__', (None,)) self.checkraises(ValueError, '%(foo', '__mod__', {}) self.checkraises(TypeError, '%(foo)s %(bar)s', '__mod__', ('foo', 42)) self.checkraises(TypeError, '%d', '__mod__', "42") # not numeric |