06-create-client.t #1

  • //
  • p4perl/
  • r16.1/
  • t/
  • 06-create-client.t
  • View
  • Commits
  • Open Download .zip Download (611 B)
use Test::More tests => 9;
BEGIN { use_ok( 'P4' ); }

# Load test utils
unshift( @INC, "." );
unshift( @INC, "t" );
require_ok( "p4test" );

my $test = new P4::Test;
my $p4 = $test->InitClient();

ok( defined( $p4 ) );
$p4->SetProg( $0 );
ok( $p4->Connect() );

my $client = $p4->FetchClient();
ok( defined( $client ) );
ok( ref( $client ) );

$client->{ 'Description' } = "Client for P4Perl Tests";
$client->{ 'Root' } = $test->ClientRoot();
$p4->SaveClient( $client );
ok( $p4->ErrorCount() == 0 );

@info = $p4->RunInfo();
ok( length( scalar(@info) ) == 1 );
ok( $info[0]->{ 'clientName' } ne "*unknown*" );
# Change User Description Committed
#1 21613 C. Thomas Tyler Populate -r -o -S //p4perl/r16.1.
//p4perl/main/t/06-create-client.t
#1 21593 C. Thomas Tyler Populate -o //guest/perforce_software/p4perl/main/...
//p4perl/main/....
//guest/perforce_software/p4perl/main/t/06-create-client.t
#1 15920 Matt Attaway Move p4perl files into the main directory
//guest/perforce_software/p4perl/t/06-create-client.t
#2 8494 Paul Allen Minor fixes to test cases for update to Perl 5.16 and P4D 13.3.

Action resolve order changed in P4D causes test case '35-reslove-action' to fail.
 - Update test to count 'ActionResolve' and 'Resolve' method calls.

Perl 5.16 warns on @array length without use of scalar() function.
 - Added scalar(...) to tests '05-environ' and '06-create-client'.
#1 8486 Paul Allen Initial population of P4PERL

from:
   //depot/main/p4-perl/...@565514
   //depot/main/p4-doc/user/p4perlnotes.txt@565514