summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2015-05-09 04:25:18 (GMT)
committerBenjamin Peterson <benjamin@python.org>2015-05-09 04:25:18 (GMT)
commit65bcdd7195666e20eb56a7d49b5dd0ee2278e506 (patch)
tree409692635ac463a111176be3a8cf978a5d7165cd /Lib
parent07abcf58d98f2f2ae36a4cb20331b9e72b36ad4d (diff)
downloadcpython-65bcdd7195666e20eb56a7d49b5dd0ee2278e506.zip
cpython-65bcdd7195666e20eb56a7d49b5dd0ee2278e506.tar.gz
cpython-65bcdd7195666e20eb56a7d49b5dd0ee2278e506.tar.bz2
ensure .keywords is always a dict
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_functools.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_functools.py b/Lib/test/test_functools.py
index 0375601c..36f154a 100644
--- a/Lib/test/test_functools.py
+++ b/Lib/test/test_functools.py
@@ -77,9 +77,11 @@ class TestPartial:
# exercise special code paths for no keyword args in
# either the partial object or the caller
p = self.partial(capture)
+ self.assertEqual(p.keywords, {})
self.assertEqual(p(), ((), {}))
self.assertEqual(p(a=1), ((), {'a':1}))
p = self.partial(capture, a=1)
+ self.assertEqual(p.keywords, {'a':1})
self.assertEqual(p(), ((), {'a':1}))
self.assertEqual(p(b=2), ((), {'a':1, 'b':2}))
# keyword args in the call override those in the partial object