diff --git a/regress/README b/regress/README index 2567aaf..a27967f 100644 --- a/regress/README +++ b/regress/README @@ -33,7 +33,8 @@ Changelog test_set_nw_dst/ -> cleanup test_failover_startup/ -> argv parsing was broken - Add new test : test_set_dl_nw_flip -> flip dl & nw addresses - - Add new command line options : no_vlan, no_slicing and no_barrier + - Add new command line options : no_vlan, no_slicing and no_barrier, + no_emerg - Add ability to run a single test with --testPath - New debugging function : dpctl_show_flows diff --git a/regress/bin/of_hp_test.pl b/regress/bin/of_hp_test.pl index 60aed9a..e3b6e40 100755 --- a/regress/bin/of_hp_test.pl +++ b/regress/bin/of_hp_test.pl @@ -43,6 +43,9 @@ push @ARGV, "--no_slicing"; # The hardware can not support barrier push @ARGV, "--no_barrier"; +# The hardware can not support emergency flow table +push @ARGV, "--no_emerg"; + # Check for listener if ( defined($ENV{'OFT_HP_LISTENER'}) ) { push @ARGV, "--listener=$ENV{OFT_HP_LISTENER}"; diff --git a/regress/bin/of_hp_test_6600.pl b/regress/bin/of_hp_test_6600.pl index 5890609..e141def 100755 --- a/regress/bin/of_hp_test_6600.pl +++ b/regress/bin/of_hp_test_6600.pl @@ -43,6 +43,9 @@ push @ARGV, "--no_slicing"; # The hardware can not support barrier push @ARGV, "--no_barrier"; +# The hardware can not support emergency flow table +push @ARGV, "--no_emerg"; + # Check for listener if ( defined($ENV{'OFT_HP_LISTENER'}) ) { push @ARGV, "--listener=$ENV{OFT_HP_LISTENER}"; diff --git a/regress/bin/of_ovs_test.pl b/regress/bin/of_ovs_test.pl index 2aa4241..a842aa6 100755 --- a/regress/bin/of_ovs_test.pl +++ b/regress/bin/of_ovs_test.pl @@ -40,6 +40,9 @@ push @ARGV, "--less_ports"; # Don't bother with QoS currently, it's broken... push @ARGV, "--no_slicing"; +# The bother with emergency flow table tests, it's not supported... +push @ARGV, "--no_emerg"; + # Don't forget to configure the OVS_ROOT environment variable # Jean II diff --git a/regress/bin/of_ovs_user_test.pl b/regress/bin/of_ovs_user_test.pl index 5f1d20b..9587dcb 100755 --- a/regress/bin/of_ovs_user_test.pl +++ b/regress/bin/of_ovs_user_test.pl @@ -33,6 +33,9 @@ push @ARGV, "--root=$ENV{'OFT_ROOT'}", "--common-st-args=ovs_user", "--controlle # Use a single random port instead of all four push @ARGV, "--less_ports"; +# The bother with emergency flow table tests, it's not supported... +push @ARGV, "--no_emerg"; + # Don't forget to configure the OVS_ROOT environment variable # Jean II diff --git a/regress/bin/of_ovs_user_veth_test.pl b/regress/bin/of_ovs_user_veth_test.pl index 8bd2488..037d560 100755 --- a/regress/bin/of_ovs_user_veth_test.pl +++ b/regress/bin/of_ovs_user_veth_test.pl @@ -35,6 +35,9 @@ push @ARGV, "--root=$ENV{'OFT_ROOT'}", "--common-st-args=ovs_user", "--controlle # Use a single random port instead of all four push @ARGV, "--less_ports"; +# The bother with emergency flow table tests, it's not supported... +push @ARGV, "--no_emerg"; + # Don't forget to configure the OVS_ROOT environment variable # Jean II diff --git a/regress/lib/Perl5/Test/RegressTest.pm b/regress/lib/Perl5/Test/RegressTest.pm index 62fb0bf..3ed8ca2 100644 --- a/regress/lib/Perl5/Test/RegressTest.pm +++ b/regress/lib/Perl5/Test/RegressTest.pm @@ -69,6 +69,7 @@ my $ignoreByteCount; my $noVlan; my $noSlicing; my $noBarrier; +my $noEmerg; my $lessPorts; sub run_regress_test { @@ -102,6 +103,7 @@ sub run_regress_test { "no_vlan" => \$noVlan, "no_slicing" => \$noSlicing, "no_barrier" => \$noBarrier, + "no_emerg" => \$noEmerg, "less_ports" => \$lessPorts ) and ( $help eq '' ) @@ -284,7 +286,7 @@ SYNOPSIS [--map ] [--project ] [--project ] ... [--testPath ] - [--no_vlan] [--no_slicing] [--no_barrier] + [--no_vlan] [--no_slicing] [--no_barrier] [--no_emerg] [--ci ] [--citest ] [--listener ] [--failfast] @@ -338,6 +340,9 @@ OPTIONS --no_barrier Do not run barrier tests + --no_emerg + Do not run emergency flow table tests + --listener Specify port that the switch is listening on @@ -624,6 +629,10 @@ sub runTest { if ( defined($noBarrier) ) { $args .= " --no_barrier"; } + # Some platforms can not do emergency flow table + if ( defined($noEmerg) ) { + $args .= " --no_emerg"; + } # Don't do all ports on some platforms, it's slow and useless... if ( defined($lessPorts) ) { diff --git a/regress/lib/Perl5/Test/TestLib.pm b/regress/lib/Perl5/Test/TestLib.pm index a73558d..54b2ad9 100644 --- a/regress/lib/Perl5/Test/TestLib.pm +++ b/regress/lib/Perl5/Test/TestLib.pm @@ -234,6 +234,7 @@ sub nftest_init { "no_vlan", "no_slicing", "no_barrier", + "no_emerg", "less_ports" ) ) diff --git a/regress/projects/controller_disconnect/regress/test_emergency_table/run.pl b/regress/projects/controller_disconnect/regress/test_emergency_table/run.pl index a6bd478..7e07a6c 100755 --- a/regress/projects/controller_disconnect/regress/test_emergency_table/run.pl +++ b/regress/projects/controller_disconnect/regress/test_emergency_table/run.pl @@ -85,21 +85,23 @@ sub test_emergency_cache_second { sub my_test { my ($sock, $options_ref) = @_; - #This test uses two ports - my $inport = 0; - my $outport = 1; - my $wildcards = 0; #exact match + if ( not defined( $$options_ref{'no_emerg'} ) ) { + #This test uses two ports + my $inport = 0; + my $outport = 1; + my $wildcards = 0; #exact match - # Wait until switch notices disconnection. it depends on implementation - my $wait_timer = 20; + # Wait until switch notices disconnection. it depends on implementation + my $wait_timer = 20; - my $test_pkt = test_emergency_cache_first($ofp, $sock, $options_ref, $inport, $outport, $wildcards); + my $test_pkt = test_emergency_cache_first($ofp, $sock, $options_ref, $inport, $outport, $wildcards); - # Wait until ofprotocol notices that connection is broken - sleep $wait_timer; + # Wait until ofprotocol notices that connection is broken + sleep $wait_timer; - # chek if the emergency table has become active - test_emergency_cache_second($test_pkt, $options_ref, $inport, $outport); + # chek if the emergency table has become active + test_emergency_cache_second($test_pkt, $options_ref, $inport, $outport); + } } run_black_box_test( \&my_test, \@ARGV );