[New-bugs-announce] [issue33309] Unittest Mock objects do not freeze arguments they are called with

Nathaniel Duarte report at bugs.python.org
Wed Apr 18 11:53:04 EDT 2018


New submission from Nathaniel Duarte <slacknate at gmail.com>:

It is possible to make a call with a Mock object, for example, where a dictionary is passed to the mock and later modified. If a call assertion is then made against the mock using the initial value/contents of the dictionary the assertion will fail.

----------
components: Library (Lib)
files: mock_issue.py
messages: 315456
nosy: slacknate
priority: normal
severity: normal
status: open
title: Unittest Mock objects do not freeze arguments they are called with
type: behavior
versions: Python 3.7
Added file: https://bugs.python.org/file47539/mock_issue.py

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33309>
_______________________________________


More information about the New-bugs-announce mailing list