Closed GoogleCodeExporter closed 9 years ago
This is the classic problem of making assertions with mutable arguments. The
mock assert methods keep references to their arguments, so if you mutate the
argument then assertions can fail.
There's an explanation, along with a workaround, in the docs:
http://www.voidspace.org.uk/python/mock/examples.html#coping-with-mutable-argume
nts
Original comment by fuzzyman
on 22 Apr 2014 at 11:14
Original issue reported on code.google.com by
vineeth....@gmail.com
on 21 Apr 2014 at 11:05