~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/lib/mtr_cases.pl

  • Committer: Brian Aker
  • Date: 2010-01-27 18:58:12 UTC
  • Revision ID: brian@gaz-20100127185812-n62n0vwetnx8jrjy
Remove dead code.

Show diffs side-by-side

added added

removed removed

Lines of Context:
141
141
        #
142
142
        # Append the criteria for sorting, in order of importance.
143
143
        #
144
 
        push(@criteria, "ndb=" . ($tinfo->{'ndb_test'} ? "1" : "0"));
145
144
        # Group test with equal options together.
146
145
        # Ending with "~" makes empty sort later than filled
147
146
        push(@criteria, join("!", sort @{$tinfo->{'master_opt'}}) . "~");
214
213
 
215
214
  mtr_verbose("Collecting: $suite");
216
215
 
 
216
  my $suitepath= "$::glob_suite_path";
217
217
  my $suitedir= "$::glob_mysql_test_dir"; # Default
218
218
  if ( $suite ne "main" )
219
219
  {
220
 
    $suitedir= mtr_path_exists("$suitedir/suite/$suite",
 
220
    $suitedir= mtr_path_exists(
 
221
             "$suitepath/$suite/drizzle-tests",
 
222
             "$suitepath/$suite/tests",
 
223
             "$suitedir/suite/$suite",
221
224
                               "$suitedir/$suite");
222
225
    mtr_verbose("suitedir: $suitedir");
223
226
  }
526
529
 
527
530
  my $tinfo= {};
528
531
  $tinfo->{'name'}= basename($suite) . ".$tname";
529
 
  $tinfo->{'result_file'}= "$resdir/$tname.result";
 
532
  if ( -f "$resdir/$::opt_engine/$tname.result")
 
533
  {
 
534
    $tinfo->{'result_file'}= "$resdir/$::opt_engine/$tname.result";
 
535
  }
 
536
  else
 
537
  {
 
538
    $tinfo->{'result_file'}= "$resdir/$tname.result";
 
539
  }
530
540
  $tinfo->{'component_id'} = $component_id;
531
541
  push(@$cases, $tinfo);
532
542
 
622
632
      {
623
633
        # Specifies the file mysqltest should compare
624
634
        # output against
625
 
        $tinfo->{'result_file'}= "r/$value.result";
 
635
        if ( -f "r/$::opt_engine/$value.result")
 
636
        {
 
637
          $tinfo->{'result_file'}= "r/$::opt_engine/$value.result";
 
638
        }
 
639
        else
 
640
        {
 
641
          $tinfo->{'result_file'}= "r/$value.result";
 
642
        }
 
643
 
626
644
        next;
627
645
      }
628
646
 
773
791
        if ( $::used_default_engine =~ /^innodb/i );
774
792
    }
775
793
 
776
 
    if ( $tinfo->{'big_test'} and ! $::opt_big_test )
777
 
    {
778
 
      $tinfo->{'skip'}= 1;
779
 
      $tinfo->{'comment'}= "Test need 'big-test' option";
780
 
      return;
781
 
    }
782
 
 
783
794
    if ( $tinfo->{'ndb_extra'} and ! $::opt_ndb_extra_test )
784
795
    {
785
796
      $tinfo->{'skip'}= 1;
800
811
      $tinfo->{'comment'}= "Test need debug binaries";
801
812
      return;
802
813
    }
803
 
 
804
 
    {
805
 
      if ( $::opt_with_ndbcluster_only )
806
 
      {
807
 
        # Only the ndb test should be run, all other should be skipped
808
 
        $tinfo->{'skip'}= 1;
809
 
        $tinfo->{'comment'}= "Only ndbcluster tests(--with-ndbcluster-only)";
810
 
        return;
811
 
      }
812
 
    }
813
 
 
814
 
    if ( $tinfo->{'need_binlog'} )
815
 
    {
816
 
      if (grep(/^--skip-log-bin/,  @::opt_extra_mysqld_opt) )
817
 
      {
818
 
        $tinfo->{'skip'}= 1;
819
 
        $tinfo->{'comment'}= "Test need binlog";
820
 
        return;
821
 
      }
822
 
    }
823
 
    else
824
 
    {
825
 
      if ( $::mysql_version_id >= 50100 )
826
 
      {
827
 
        # Test does not need binlog, add --skip-binlog to
828
 
        # the options used when starting it
829
 
        push(@{$tinfo->{'master_opt'}}, "--skip-log-bin");
830
 
      }
831
 
    }
832
 
 
833
814
  }
834
815
}
835
816
 
850
831
  "sup_binlog_formats", ["mixed","statement"]],
851
832
 ["include/have_binlog_format_row_or_statement.inc",
852
833
  "sup_binlog_formats", ["row","statement"]],
853
 
 ["include/big_test.inc", "big_test", 1],
854
834
 ["include/have_debug.inc", "need_debug", 1],
855
835
 ["require_manager", "require_manager", 1],
856
836
);