incubator-bloodhound-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Ollos <ryan.ol...@wandisco.com>
Subject Re: [Apache Bloodhound] #469: Some batch modify unit test cases are failing
Date Mon, 25 Mar 2013 18:45:27 GMT
On Mon, Mar 18, 2013 at 11:33 PM, Olemis Lang <olemis@gmail.com> wrote:

> On 3/18/13, Ryan Ollos <ryan.ollos@wandisco.com> wrote:
> > On Mon, Mar 18, 2013 at 1:36 PM, Apache Bloodhound <
> > bloodhound-dev@incubator.apache.org> wrote:
> >
> >> #469: Some batch modify unit test cases are failing
> >>
> [...]
> >>
> >> Comment:
> >>
> >>  [attachment:t469_r1457691_trac_test_batch_regression.diff Attached
> >> patch]
> >>  should fix this .
> >>
> >
> > Have you figured out already why the TicketSystem didn't need to be
> enabled
> > prior to the addition of ITicketFieldProvider? I'm just starting to look
> at
> > this, but it's not obvious to me so far.
> >
>
> Oh yes !
> Just because in Trac test suite instantiates `TicketSystem` class this
> way `TicketSystem(env)` rather than `env[TicketSystem]` . The former
> will *always* return the instance whereas the later also checks
> whether component class is enabled . Now , after introducing the
> interface and considering that `TicketSystem` itself is an implementor
> , then it will not be listed in the corresponding extension point and
> thereby «built-in» ticket fields will not be contributed .
>
> In practice , in order to make `TicketSystem` work it must be enabled
> ... so ... no defect in the SUT .


Thanks! It took me a while to wrap my head around why the TicketSystem
Component needed to be enabled in the test class, but your explanation
helped a lot. I'll commit the patch now.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message