~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/test-run.pl

  • Committer: Monty Taylor
  • Date: 2008-12-16 21:39:09 UTC
  • mto: This revision was merged to the branch mainline in revision 713.
  • Revision ID: monty@inaugust.com-20081216213909-qxc0zfy9nc0ls98a
Some more cleanups to mtr.

Show diffs side-by-side

added added

removed removed

Lines of Context:
590
590
    $opt_mtr_build_thread= $ENV{'MTR_BUILD_THREAD'};
591
591
  }
592
592
 
593
 
  # We require that we are in the "mysql-test" directory
594
 
  # to run drizzle-test-run
595
 
  #if (! -f $glob_scriptname)
596
 
  #{
597
 
  #  mtr_error("Can't find the location for the drizzle-test-run script\n" .
598
 
  #            "Go to to the mysql-test directory and execute the script " .
599
 
  #            "as follows:\n./$glob_scriptname");
600
 
  #}
601
 
 
602
593
  if ( -d "../drizzled" )
603
594
  {
604
595
    $source_dist=  1;
780
771
  # --------------------------------------------------------------------------
781
772
  # Set the "var/" directory, as it is the base for everything else
782
773
  # --------------------------------------------------------------------------
783
 
  if ( ! -d $opt_vardir )
 
774
  if ( ! $opt_vardir )
784
775
  {
785
 
    print "Overriding opt_vardir\n";
786
776
    $opt_vardir= $default_vardir;
787
777
  }
788
778
  elsif ( $mysql_version_id < 50000 and
804
794
  # Chop off any "c:", DBUG likes a unix path ex: c:/src/... => /src/...
805
795
  $path_vardir_trace=~ s/^\w://;
806
796
 
807
 
  $opt_vardir= collapse_path(rel2abs($opt_vardir));
 
797
  $opt_vardir= collapse_path($opt_vardir);
808
798
 
809
799
  # --------------------------------------------------------------------------
810
800
  # Set tmpdir
1432
1422
  
1433
1423
  $ENV{'LC_COLLATE'}=         "C";
1434
1424
  $ENV{'USE_RUNNING_SERVER'}= $opt_extern;
1435
 
  $ENV{'DRIZZLE_TEST_DIR'}=     collapse_path(rel2abs($glob_mysql_test_dir));
 
1425
  $ENV{'DRIZZLE_TEST_DIR'}=     collapse_path($glob_mysql_test_dir);
1436
1426
  $ENV{'MYSQLTEST_VARDIR'}=   $opt_vardir;
1437
1427
  $ENV{'DRIZZLE_TMP_DIR'}=      $opt_tmpdir;
1438
1428
  $ENV{'MASTER_MYSOCK'}=      $master->[0]->{'path_sock'};
1791
1781
  }
1792
1782
 
1793
1783
  # Make a link std_data_ln in var/ that points to std_data
1794
 
  symlink(collapse_path(rel2abs("$glob_mysql_test_dir/std_data")),
 
1784
  symlink(collapse_path("$glob_mysql_test_dir/std_data"),
1795
1785
          "$opt_vardir/std_data_ln");
1796
1786
 
1797
1787
  # Remove old log files
2491
2481
 
2492
2482
  mtr_add_arg($args, "%s--no-defaults", $prefix);
2493
2483
 
2494
 
  $path_my_basedir= collapse_path(rel2abs($path_my_basedir));
 
2484
  $path_my_basedir= collapse_path($path_my_basedir);
2495
2485
  mtr_add_arg($args, "%s--basedir=%s", $prefix, $path_my_basedir);
2496
2486
 
2497
2487
  if ($opt_engine)
3521
3511
 
3522
3512
sub collapse_path ($) {
3523
3513
 
3524
 
    my $c_path= shift;
 
3514
    my $c_path= rel2abs(shift);
3525
3515
    my $updir  = updir($c_path);
3526
3516
    my $curdir = curdir($c_path);
3527
3517