[Python-checkins] Fix misused variable that was preventing permutations of classes from being tested (GH-93935)

zooba webhook-mailer at python.org
Thu Jul 28 18:43:12 EDT 2022


https://github.com/python/cpython/commit/390847922c8f93db6f639d6e0ab3e53aefa60c76
commit: 390847922c8f93db6f639d6e0ab3e53aefa60c76
branch: main
author: Jingxuan He <LostBenjamin at users.noreply.github.com>
committer: zooba <steve.dower at microsoft.com>
date: 2022-07-28T23:42:51+01:00
summary:

Fix misused variable that was preventing permutations of classes from being tested (GH-93935)

files:
M Lib/test/test_functools.py

diff --git a/Lib/test/test_functools.py b/Lib/test/test_functools.py
index 767d2a9c1aea9..a4b098a2a5b8e 100644
--- a/Lib/test/test_functools.py
+++ b/Lib/test/test_functools.py
@@ -2003,7 +2003,7 @@ class D(collections.defaultdict):
         c.MutableSequence.register(D)
         bases = [c.MutableSequence, c.MutableMapping]
         for haystack in permutations(bases):
-            m = mro(D, bases)
+            m = mro(D, haystack)
             self.assertEqual(m, [D, c.MutableSequence, c.Sequence, c.Reversible,
                                  collections.defaultdict, dict, c.MutableMapping, c.Mapping,
                                  c.Collection, c.Sized, c.Iterable, c.Container,



More information about the Python-checkins mailing list