>   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"/>

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


Jan


> /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java,v
>            exe.setCommandline(toExecute.getCommandline());
>            try {
>   +            int returncode = exe.execute();
>   +            if (returncode != 0) {
>   +                throw new BuildException("'" +
>   +                        toExecute.getExecutable() +
>   +                        "' failed with exit code "+returncode);
>   +            }
>            }

Reply via email to