[pygtk] Functional/Acceptance Testing Using guitest

Lawrence Oluyede l.oluyede at gmail.com
Thu May 25 21:28:32 WST 2006


On 5/25/06, baiju m <baiju.m.mail at gmail.com> wrote:
> On 5/25/06, Lawrence Oluyede <l.oluyede at gmail.com> wrote:
> > - assert type(button) == gtk.Button is not really pythonic and it's
> > quite deprecated because it does not support inheritance. Use assert
> > isinstance(button, gtk.Button)
>
> I often hear isinstance considered harmful, see this
> http://www.canonical.org/~kragen/isinstance/

AFAIK the article is 4 years old and refers 2.1 version of Python. Lot
of things have changed since 2.2 and the introduction of new style
classes. Anyway it doesn't really matter for your example.

> I think for simple examples it is better to improve "local understandings"
> than going for abstractions.

Ok :-)

-- 
Lawrence
http://www.oluyede.org/blog


More information about the pygtk mailing list