diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2017-08-03 11:45:23 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-03 11:45:23 +0300 |
commit | 5075416b8fedc5526b643dabc915f7945fa0d969 (patch) | |
tree | 31e23d9e4dbda6c41dc8faf831cc543e9e4e89c9 /Lib/test/test_re.py | |
parent | 25e4f779d7ae9f37a1933cb5cbfad06e673c01f9 (diff) | |
download | cpython-git-5075416b8fedc5526b643dabc915f7945fa0d969.tar.gz |
bpo-30978: str.format_map() now passes key lookup exceptions through. (#2790)
Previously any exception was replaced with a KeyError exception.
Diffstat (limited to 'Lib/test/test_re.py')
-rw-r--r-- | Lib/test/test_re.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_re.py b/Lib/test/test_re.py index 0ea5a20469..e9c07a04f5 100644 --- a/Lib/test/test_re.py +++ b/Lib/test/test_re.py @@ -468,7 +468,7 @@ class ReTests(unittest.TestCase): m[(0,)] with self.assertRaisesRegex(IndexError, 'no such group'): m[(0, 1)] - with self.assertRaisesRegex(KeyError, 'a2'): + with self.assertRaisesRegex(IndexError, 'no such group'): 'a1={a2}'.format_map(m) m = pat.match('ac') |