Re: Nant property passed to CC.NET for pass/fail condition?

Dominik Guder <[email protected]> Tue, 20 Mar 2012 07:08:02 +0100
Newsgroups gmane.comp.windows.dotnet.nant.user
Message-ID <[email protected]>
Hi Chris,

I don't know what your "fail" target does, but what bob mentionened =

before was using the <fail> task:
http://nant.sourceforge.net/release/latest/help/tasks/fail.html

<target name=3D"set_nant_failure">
   <fail message=3D"build failed" if=3D"${(not project1_ok) or (not =

project2_ok)}" />
</target>

hth
Dominik




Am 19.03.2012 23:00, schrieb Chris Fouts:
> To further explain, here=92s how I call my evaluate and call my <fail> ta=
rget
>
> <target name=3D"set_nant_failure">
>
> <call target=3D"fail" if=3D"${(not project1_ok) or {not project2_ok)}" />
>
> </target>
>
> The project1_ok and project2_ok are bools that are set CORRECTLY by
> evaluating resultproperty values earlier in script.
>
> *From:*Chris Fouts [mailto:[email protected]]
> *Sent:* Monday, March 19, 2012 5:50 PM
> *To:* [email protected]
> *Subject:* Re: [NAnt-users] Nant property passed to CC.NET for pass/fail
> condition?
>
> I thought I had this figured out.
>
> I see that I=92m calling my <fail> task in my Nant script. I see it in my
> ccnet console
>
> fail:
>
> [echo] ******** BUILD FAILED! ******
>
> BUILD SUCCEEDED - 1 non-fatal error(s), 2 warning(s)
>
> Total time: 25.8 seconds.
>
> But how come ccnet still says =93BUILD SUCCEEDED=94?
>
> -chris
>


-- =

The answer to the great question of life,
the universe and everything is 42 (Douglas Adams)

---------------------------------------------------------------------------=
---
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here =

http://p.sf.net/sfu/sfd2d-msazure