Re: doctest redundant mock class instantiations

2008-10-24 Thread Marc 'BlackJack' Rintsch
On Sat, 25 Oct 2008 03:29:39 +, Steven D'Aprano wrote: > Personally, I tend to use a combination of approaches. Since doctests > aren't intended for full test coverage, I use *short* tests in methods. > If I can't make a test short, it doesn't go into the method doctest. For > more extensive t

Re: doctest redundant mock class instantiations

2008-10-24 Thread Steven D'Aprano
On Fri, 24 Oct 2008 17:16:50 -0700, mde wrote: > I'm wondering if there is a "best practice" for *creating doctests in > methods* that reduces clutter/duplication of dummy instantiations. In > the following code there are five (labeled 1-5) possible places to put a > dummy mock instantiation. I

doctest redundant mock class instantiations

2008-10-24 Thread mde
I'm wondering if there is a "best practice" for *creating doctests in methods* that reduces clutter/duplication of dummy instantiations. In the following code there are five (labeled 1-5) possible places to put a dummy mock instantiation. I have the impression that creating the dummies in every m