[Zope3-dev] doctest: Get type of object

Florian Lindner mailinglists at xgm.de
Tue Jan 24 17:32:48 EST 2006


Am Dienstag, 24. Januar 2006 22:57 schrieb Tim Peters:
> [Florian Lindner]
>
> > I've tried:
> >
> > Failed example:
> >     homeFolder #doctest: +ELLIPSIS
> > Expected:
> >     <zope.app.file.file.File object at ...>
> > Got nothing
> >
> >
> > I've also tried it without the #doctest....
> >
> > Why do I get just nothing?
>
> That's expected if (and only if) `homeFolder` is bound to `None`.
> What happens if you change the line to:
>
>       print homeFolder #doctest: +ELLIPSIS
>
> ? That added "print " at the front, and will display:
>
>     None
>
> if homeFolder is in fact bound to None.

Thanks, it works now. Actually I don't know exactly where the error was... 
anyway, it vanished.

Florian


More information about the Zope3-dev mailing list