◐ Shell
reader mode source ↗
Skip to content

bpo-2661: Make mapping tests better usable for custom mapping classes.#11157

Merged
miss-islington merged 1 commit into
python:masterfrom
doerwalter:mapping-tests
Jun 6, 2019
Merged

bpo-2661: Make mapping tests better usable for custom mapping classes.#11157
miss-islington merged 1 commit into
python:masterfrom
doerwalter:mapping-tests

Conversation

@doerwalter

@doerwalter doerwalter commented Dec 14, 2018

Copy link
Copy Markdown
Contributor

In test_fromkeys() the derived test class now supports all arguments in its
constructor so that the class to be tested can use its own constructor in its
fromkeys() implementation.

In test_mutatingiteration() the test fails as soon as iterating over a
dictionary with one entry and adding new entries in the loop iterates more
than once (to avoid endless loops in faulty implementations).

https://bugs.python.org/issue2661

In test_fromkeys() the derived test class now supports all arguments in its
constructor so that the class to be tested can use its own constructor in its
fromkeys() implementation.

In test_mutatingiteration() the test fails as soon as iterating over a
dictionary with one entry and adding new entries in the loop iterates more
than once (to avoid endless loops in faulty implementations).
@csabella

csabella commented Jun 5, 2019

Copy link
Copy Markdown
Contributor

@doerwalter, should this be merged? Thanks!

@doerwalter

Copy link
Copy Markdown
Contributor Author

Its a tiny fix for an ancient issue, so yes, this should be merged.

@miss-islington miss-islington merged commit 6af2303 into python:master Jun 6, 2019
@csabella

csabella commented Jun 6, 2019

Copy link
Copy Markdown
Contributor

@doerwalter, thank you! This has been merged.

@doerwalter doerwalter deleted the mapping-tests branch July 19, 2019 10:07
DinoV pushed a commit to DinoV/cpython that referenced this pull request Jan 14, 2020
pythonGH-11157)

In test_fromkeys() the derived test class now supports all arguments in its
constructor so that the class to be tested can use its own constructor in its
fromkeys() implementation.

In test_mutatingiteration() the test fails as soon as iterating over a
dictionary with one entry and adding new entries in the loop iterates more
than once (to avoid endless loops in faulty implementations).



https://bugs.python.org/issue2661
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants