Raymond Hettinger <[email protected]> added the comment:
The test code now includes this:
def test_shuffle_random_argument(self):
# Test random argument to shuffle.
shuffle = self.gen.shuffle
mock_random = unittest.mock.Mock(return_value=0.5)
seq = bytearray(b'abcdefghijk')
shuffle(seq, mock_random)
mock_random.assert_called_with()
Thank you for the suggestion.
----------
resolution: -> out of date
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue24533>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com