[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Michael Foord
Michael Foord added the comment: Fixed in revision 71043. -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ P

[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Michael Foord
Michael Foord added the comment: We can fix this by wrapping the assert functions in our assert register as deep-copyable objects. (And then unwrapping when we fetch them.) -- ___ Python tracker ___

[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Michael Foord
Michael Foord added the comment: This is a workaround: import copy copy._deepcopy_dispatch[types.MethodType] = copy._deepcopy_atomic -- ___ Python tracker ___ __

[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Michael Foord
Changes by Michael Foord : -- nosy: +michael.foord ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: -> gregory.p.smith nosy: +gregory.p.smith ___ Python tracker ___ ___ Python-bugs-list mail

[issue5660] Cannot deepcopy unittest.TestCase instances

2009-04-01 Thread Andrew Bennetts
New submission from Andrew Bennetts : Here's a demonstration of the bug: >>> from unittest import TestCase >>> class MyTest(TestCase): ... def test_foo(self): pass ... >>> tc = MyTest('test_foo') >>> import copy >>> copy.deepcopy(tc) Traceback (most recent call last): File "", line 1, in