http://stackoverflow.com/questions/6034513/can-i-avoid-a-dependency-cycle-with-one-edge-being-a-test-dependency

On Tue, May 17, 2011 at 6:49 PM, Gabriele Kahlout
<gabri...@mysimpatico.com>wrote:

>
>
>
> On Tue, May 17, 2011 at 3:52 PM, Gabriele Kahlout <
> gabri...@mysimpatico.com> wrote:
>
>>
>>
>> On Tue, May 17, 2011 at 3:44 PM, Steven A Rowe <sar...@syr.edu> wrote:
>>
>>> Hi Gabriele,
>>>
>>> On 5/17/2011 at 9:34 AM, Gabriele Kahlout wrote:
>>> > Solr Core should declare a test dependency on Solr Test Framework.
>>>
>>> I agree:
>>>
>>> - Solr Core should have a test-scope dependency on Solr Test Framework.
>>> - Solr Test Framework should have a compile-scope dependency on Solr
>>> Core.
>>>
>>> But Maven views this as a circular dependency.
>>>
>>
>> I've seen, but adding it with <scope> test </scope> works. The logic: the
>> src is compiled first and then re-used (I'm assuming maven does something
>> smart about not including the full jar).
>>
>
> Not quite. I've tried a demo and the reactor complains. I'll try to see if
> maven could become 'smarter', or if the 2-build phase solution will work.
>
> The projects in the reactor contain a cyclic reference: Edge between
> 'Vertex{label='com.mysimpatico:TestFramework:1.0-SNAPSHOT'}' and
> 'Vertex{label='org.apache:DummyCore:1.0-SNAPSHOT'}' introduces to cycle in
> the graph org.apache:DummyCore:1.0-SNAPSHOT -->
> com.mysimpatico:TestFramework:1.0-SNAPSHOT -->
> org.apache:DummyCore:1.0-SNAPSHOT -> [Help 1]
>
>
>
>>
>>
>>
>>
>>> The workaround: Solr Core includes the source of Solr Test Framework as
>>> part of its test source code.  It's not pretty, but it works.
>>>
>>> I'd be happy to entertain other (functional) approaches.
>>>
>>
>> In dp4j.com pom.xml I build in 2 phases to compile with the same
>> annotations in the project itself (but i don't think we need that here)
>>
>>
>>>
>>> Steve
>>>
>>>
>>
>>
>> --
>> Regards,
>> K. Gabriele
>>
>> --- unchanged since 20/9/10 ---
>> P.S. If the subject contains "[LON]" or the addressee acknowledges the
>> receipt within 48 hours then I don't resend the email.
>> subject(this) ∈ L(LON*) ∨ ∃x. (x ∈ MyInbox ∧ Acknowledges(x, this) ∧
>> time(x) < Now + 48h) ⇒ ¬resend(I, this).
>>
>> If an email is sent by a sender that is not a trusted contact or the email
>> does not contain a valid code then the email is not received. A valid code
>> starts with a hyphen and ends with "X".
>> ∀x. x ∈ MyInbox ⇒ from(x) ∈ MySafeSenderList ∨ (∃y. y ∈ subject(x) ∧ y ∈
>> L(-[a-z]+[0-9]X)).
>>
>>
>
>
> --
> Regards,
> K. Gabriele
>
> --- unchanged since 20/9/10 ---
> P.S. If the subject contains "[LON]" or the addressee acknowledges the
> receipt within 48 hours then I don't resend the email.
> subject(this) ∈ L(LON*) ∨ ∃x. (x ∈ MyInbox ∧ Acknowledges(x, this) ∧
> time(x) < Now + 48h) ⇒ ¬resend(I, this).
>
> If an email is sent by a sender that is not a trusted contact or the email
> does not contain a valid code then the email is not received. A valid code
> starts with a hyphen and ends with "X".
> ∀x. x ∈ MyInbox ⇒ from(x) ∈ MySafeSenderList ∨ (∃y. y ∈ subject(x) ∧ y ∈
> L(-[a-z]+[0-9]X)).
>
>


-- 
Regards,
K. Gabriele

--- unchanged since 20/9/10 ---
P.S. If the subject contains "[LON]" or the addressee acknowledges the
receipt within 48 hours then I don't resend the email.
subject(this) ∈ L(LON*) ∨ ∃x. (x ∈ MyInbox ∧ Acknowledges(x, this) ∧ time(x)
< Now + 48h) ⇒ ¬resend(I, this).

If an email is sent by a sender that is not a trusted contact or the email
does not contain a valid code then the email is not received. A valid code
starts with a hyphen and ends with "X".
∀x. x ∈ MyInbox ⇒ from(x) ∈ MySafeSenderList ∨ (∃y. y ∈ subject(x) ∧ y ∈
L(-[a-z]+[0-9]X)).

Reply via email to