ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From julian simpson <simpsonjul...@gmail.com>
Subject Re: AW: cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/option al Rpm.java
Date Mon, 21 Feb 2005 11:13:53 GMT
Hello,

On Wed, 9 Feb 2005 09:03:33 +0100, Jan.Materne@rzf.fin-nrw.de
<Jan.Materne@rzf.fin-nrw.de> wrote:
> >   Modified:
> > src/main/org/apache/tools/ant/taskdefs/optional Rpm.java
> >   Log:
> >   return code checking on rpm. How do we test this?
> 
> Using a mock object for rpm? Could return the value of a system parameter or
> file content or env variable ...
> 
> <rpm rpmBuildCommand="rpm-mock"/>
> 


I mocked out/overrode the Executor object for the unit test I
submitted; I don't want to know that rpmbuild actually runs, I just
want to ensure that we can execute it and deal with all the reponses. 
I thought it was excessive to submit Jmock with the patch, but there
could be milage in using a mock Executor so you can make tests with
mock objects for all the tasks that use the Executor.

> Because rpm runs only on *nix, the test doesnt have to be platform
> independant.

I'd like to be able to make RPM's from cygwin; does that count as a
*nix in that case?

Best,

Julian.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message