Senthil Kumaran added the comment: Verified the change and committed.
The new output behavior will be like this. ``` >>> from unittest.mock import Mock >>> mock = Mock(return_value=None) >>> for i in range(1, 10): ... mock(i) ... >>> from unittest.mock import call >>> calls = [call(i) for i in range(2, 10)] >>> mock.assert_has_calls(calls) >>> calls.append(call(100)) >>> mock.assert_has_calls(calls) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Users/senthilkumaran/python/cpython/Lib/unittest/mock.py", line 824, in assert_has_calls ) from cause AssertionError: Calls not found. Expected: [call(2), call(3), call(4), call(5), call(6), call(7), call(8), call(9), call(100)] Actual: [call(1), call(2), call(3), call(4), call(5), call(6), call(7), call(8), call(9)] ``` ---------- resolution: -> fixed stage: patch review -> resolved status: open -> closed _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25347> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com