[Python-Dev] Re: how to test behavior wrt an extension type?

Alex Martelli aleax at aleax.it
Sun Jan 16 12:39:49 CET 2005


On 2005 Jan 16, at 12:03, Fredrik Lundh wrote:

> Alex Martelli wrote:
>
>> Problem: to write unit tests showing that the current copy.py 
>> misbehaves with a classic extension
>> type, I need a classic extension type which defines __copy__ and 
>> __deepcopy__ just like /F's
>> cElementTree does.  So, I made one: a small trycopy.c and 
>> accompanying setup.py whose only purpose
>> in life is checking that instances of a classic type get copied 
>> correctly, both shallowly and
>> deeply.  But now -- where do I commit this extension type, so that 
>> the unit tests in test_copy.py
>> can do their job...?
>
> Modules/_testcapimodule.c ?
>
> (I'm using the C api to define an extension type, after all...)

Fine with me, if there are no objections I'll alter the patch 
accordingly and submit it that way.


Thanks,

Alex



More information about the Python-Dev mailing list