{
ScmRepository repo = makeScmRepository( "scm:perforce://depot/projects/pathname" );
PerforceScmProviderRepository p4Repo = (PerforceScmProviderRepository) repo.getProviderRepository();
PerforceScmProvider prov = new PerforceScmProvider();
PerforceTagCommand cmd = new PerforceTagCommand();
cmd.setLogger( prov.getLogger() );
if ( PerforceScmProvider.isLive() )
{
assertNotNull( PerforceInfoCommand.getInfo( prov.getLogger(), p4Repo ).getEntry( "User name" ) );
assertNotNull( PerforceInfoCommand.getInfo( prov.getLogger(), p4Repo ).getEntry( "Client root" ) );
assertNotNull( PerforceInfoCommand.getInfo( prov.getLogger(), p4Repo ).getEntry( "Client name" ) );
assertNotNull( PerforceInfoCommand.getInfo( prov.getLogger(), p4Repo ).getEntry( "Client host" ) );
assertNull( PerforceInfoCommand.getInfo( prov.getLogger(), p4Repo ).getEntry( "foobar" ) );
}
}