Commit 5c185c8a authored by Kevin Tew's avatar Kevin Tew

testsuite testswap update

parent a06d7439
...@@ -10,6 +10,7 @@ author 'Kevin Tew <tewk@flux.utah.edu>'; ...@@ -10,6 +10,7 @@ author 'Kevin Tew <tewk@flux.utah.edu>';
version '0.01'; version '0.01';
# Specific dependencies # Specific dependencies
requires 'Crypt::SSLeay' => '';
requires 'File::Spec' => '0.80'; requires 'File::Spec' => '0.80';
requires 'Carp' => '1.08'; requires 'Carp' => '1.08';
requires 'Modern::Perl' => '1.03'; requires 'Modern::Perl' => '1.03';
...@@ -20,13 +21,18 @@ requires 'Sys::Hostname' => '1.11'; ...@@ -20,13 +21,18 @@ requires 'Sys::Hostname' => '1.11';
requires 'Test::More' => '0.86'; requires 'Test::More' => '0.86';
requires 'Time::Local' => '1.1901'; requires 'Time::Local' => '1.1901';
requires 'TAP::Harness' => '3.16'; requires 'TAP::Harness' => '3.16';
requires 'Math::BigInt::GMP' => '';
requires 'Math::BigInt::Pari' => '';
requires 'Net::SSH::Perl' => '1.34'; requires 'Net::SSH::Perl' => '1.34';
requires 'Net::SFTP' => '0.10'; requires 'Net::SFTP' => '0.10';
requires 'Crypt::X509' => '0.32'; requires 'Crypt::X509' => '0.32';
requires 'Log::Log4perl' => '1.20'; requires 'Log::Log4perl' => '1.20';
requires 'Log::Dispatch::File' => '1.22'; requires 'Log::Dispatch::File' => '1.22';
requires 'Data::UUID' => '';
test_requires 'Test::More' => '0.42'; test_requires 'Test::More' => '0.42';
no_index 'directory' => 'demos'; no_index 'directory' => 'demos';
auto_install();
WriteAll; WriteAll;
use Modern::Perl; use Modern::Perl;
package TBConfig; package TBConfig;
use Sys::Hostname;
use Crypt::X509; use Crypt::X509;
use Tools qw(slurp); use Tools qw(slurp);
use Data::Dumper; use Data::Dumper;
...@@ -11,6 +12,7 @@ our $XMLRPC_VERSION = "0.1"; ...@@ -11,6 +12,7 @@ our $XMLRPC_VERSION = "0.1";
our $SSL_CLIENT_CERT = glob("~/.ssl/emulab.cert"); our $SSL_CLIENT_CERT = glob("~/.ssl/emulab.cert");
our $SSL_CLIENT_KEY = glob("~/.ssl/emulabkeyout.pem"); our $SSL_CLIENT_KEY = glob("~/.ssl/emulabkeyout.pem");
our $EMULAB_USER = get_emulab_user(); our $EMULAB_USER = get_emulab_user();
our $DEBUG_XML_CLIENT = (hostname() =~ /tan/);
sub get_emulab_user { sub get_emulab_user {
my $cert = slurp($SSL_CLIENT_CERT); my $cert = slurp($SSL_CLIENT_CERT);
......
test groupings test groupings
linkinfo linkinfo
event system event system
tests
THINKING ABOUT IT THINKING ABOUT IT
Test::Class Test::Class
......
...@@ -8,8 +8,18 @@ use TBConfig; ...@@ -8,8 +8,18 @@ use TBConfig;
use Data::Dumper; use Data::Dumper;
use Carp; use Carp;
use Tools; use Tools;
my $loglevel = "INFO";
$loglevel = "DEBUG" if $TBConfig::DEBUG_XML_CLIENT;
my $logger = init_tbts_logger("XMLRPCClient", undef, "INFO", "SCREEN"); my $logger = init_tbts_logger("XMLRPCClient", undef, "INFO", "SCREEN");
BEGIN {
use TBConfig;
$ENV{HTTPS_CERT_FILE} = glob($TBConfig::SSL_CLIENT_CERT);
$ENV{HTTPS_KEY_FILE} = glob($TBConfig::SSL_CLIENT_KEY);
}
has 'client' => ( isa => 'RPC::XML::Client', is => 'rw', default => sub { has 'client' => ( isa => 'RPC::XML::Client', is => 'rw', default => sub {
my $c = RPC::XML::Client->new($TBConfig::XMLRPC_SERVER, 'timeout' => (10*60)); my $c = RPC::XML::Client->new($TBConfig::XMLRPC_SERVER, 'timeout' => (10*60));
$c->{'__useragent'}->timeout(60*10); $c->{'__useragent'}->timeout(60*10);
......
#!/usr/bin/perl
use Modern::Perl;
use TestBed::TestSuite::Experiment;
use Test::More qw(no_plan);
use Data::Dumper;
require 't/old/oldtestsuite.pm';
our @pass = qw(basic cbr complete5 delaylan1 delaylink);
our @who_knows = qw( ixp lan1 multilink nodes singlenode trafgen simplelink simplex setip red ping );
our @should_fail = qw(negprerun toomanylinks toofast);
=pod
vtypes (may want to parameterize the vtypes)
S fixed (you will have to change the ns file depending on which nodes are
available)
=cut
for (@pass) {
say "Running " . $_;
my $ns = $Testbed::OldTestSuite::data->{$_}->{'nsfile'};
ok(launchpingkill('tbres', $_, $ns));
}
This diff is collapsed.
#!/usr/bin/perl #!/usr/bin/perl
use Modern::Perl;
use Data::Dumper;
{
use Getopt::Long;
my $pjobs = 1;
my $logging = 0;
my $timing;
my $verbose;
my $result = GetOptions (
"jobs=i" => \$pjobs,
"logging=i" => \$logging,
"timing" => \$timing,
"verbose" => \$verbose);
if ($pjobs > 1) {
$ENV{'HARNESS_OPTIONS'} = "j$pjobs";
}
if ($timing > 1) {
$ENV{'HARNESS_TIMER'} = 1;
}
if ($verbose) {
$ENV{'HARNESS_VERBOSE'} = 1;
$ENV{HARNESS_COLOR} = 1;
}
}
my $THARNESS = 'perl t/harness'; my $THARNESS = 'perl t/harness';
my $usage = <<"USAGE"; my $usage = <<"USAGE";
...@@ -8,7 +34,8 @@ my $usage = <<"USAGE"; ...@@ -8,7 +34,8 @@ my $usage = <<"USAGE";
USAGE USAGE
if (@ARGV) { if (@ARGV) {
my $_ = $ARGV[0]; my $cmd = $ARGV[0];
my $_ = $cmd;
if (/critic/) { exec 'perlcritic .'; } if (/critic/) { exec 'perlcritic .'; }
elsif (/test/) { exec $THARNESS; } elsif (/test/) { exec $THARNESS; }
elsif (/test/) { exec "$THARNESS t/topologies/*.t"; } elsif (/test/) { exec "$THARNESS t/topologies/*.t"; }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment