launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #05233
Re: why is LayerProcessController /not/ a mixin?
On October 19, 2010, Robert Collins wrote:
> You uncopied the list? intentional?
>
It wasn't.
> On Tue, Oct 19, 2010 at 10:42 AM, Francis J. Lacoste
>
> <francis.lacoste@xxxxxxxxxxxxx> wrote:
> > On October 18, 2010, Robert Collins wrote:
> >> On Tue, Oct 19, 2010 at 7:59 AM, Francis J. Lacoste
> >>
> >> <francis.lacoste@xxxxxxxxxxxxx> wrote:
> >> >> I don't know, but I'd guess that it's paranoia inspired by the odd
> >> >> way layers handle inheritance.
> >> >
> >> > Yes, that's the case. If you use it as a mixin, it gets taken into
> >> > account for the layer running order.
> >>
> >> Why is that a problem though?
> >
> > It might not be anymore. When this class was first in existence, it was
> > defined as a mixin and all the of the common functionality was actually
> > implemented in the layer protocol (setUp, tearDown, testSetUp,
> > testTearDown). Which of course blows up when used as a mixin (because
> > setUp will only be called once, not once per layer that use the mixin).
> >
> > Now that all the functionality is in non-layer protocol, it's probably
> > safe again to use as a mixin.
>
> But its a single instance, so it can't be setup twice *anyway*, which
> makes this make little sense.
>
I think the intent was to still share the appserver as a fixture. I agree that
making this an instance would make more sense.
--
Francis J. Lacoste
francis.lacoste@xxxxxxxxxxxxx
Attachment:
signature.asc
Description: This is a digitally signed message part.
References