[Ts2-pm-cvs-commit] ts2-pm/ts2-pm-it/ts2-pm-cli-it-simplesCommands/src/test/java/net/sf/ts2/pm/cli C
Status: Pre-Alpha
Brought to you by:
nchalumeau
From: Nicolas C. <nch...@us...> - 2005-05-27 17:42:29
|
Update of /cvsroot/ts2-pm/ts2-pm/ts2-pm-it/ts2-pm-cli-it-simplesCommands/src/test/java/net/sf/ts2/pm/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11677/src/test/java/net/sf/ts2/pm/cli Added Files: CommandExecITTest.java Log Message: validate the CLI with no real setting an no complex command --- NEW FILE: CommandExecITTest.java --- /* * ======================================================================== * * Copyright 2005-2005 TS2-PM (Sourceforge project). * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * * ======================================================================== */ package net.sf.ts2.pm.cli; import junit.framework.TestCase; /** * @author Nicolas * * TODO To change the template for this generated type comment go to * Window - Preferences - Java - Code Style - Code Templates */ public class CommandExecITTest extends TestCase { private String repoHome = System.getProperty( "user.home") + "/TS2Repository"; /** * @param arg0 */ public CommandExecITTest(String arg0) { super(arg0); } public void testCLIInvocation() { // Commandline cl = new Commandline(); // // cl.setExecutable( "ts2-pm" ); // // cl.setWorkingDirectory( repoHome ); // // cl.createArgument().setLine( "-h" ); // // StreamConsumer consumer = new DefaultConsumer(); // // try // { // CommandLineUtils.executeCommandLine( cl, consumer, consumer ); // } // catch ( CommandLineException e ) // { // fail( "unexpected exception" ); // } String [] args = {"testCLI"}; int result = TS2PackageManagerCLI.main( args ); assertEquals( "Execution fail : non zero return", 0, result ); } } |