Browse Source

Namespace temporary directories for test cases

We avoid any name clashes during the test suite run. And the hierarchy
gets more clear when debugging in case any problem arises.
Guillem Jover 16 years ago
parent
commit
791ec28602
2 changed files with 3 additions and 2 deletions
  1. 2 1
      scripts/t/500_Dpkg_Path.t
  2. 1 1
      scripts/t/900_update_alternatives.t

+ 2 - 1
scripts/t/500_Dpkg_Path.t

@@ -22,8 +22,9 @@ use_ok('Dpkg::Path', 'canonpath', 'resolve_symlink',
        'check_files_are_the_same', 'get_pkg_root_dir',
        'check_files_are_the_same', 'get_pkg_root_dir',
        'guess_pkg_root_dir', 'relative_to_pkg_root');
        'guess_pkg_root_dir', 'relative_to_pkg_root');
 
 
-my $tmpdir = 't.tmp';
+my $tmpdir = 't.tmp/500_Dpkg_Path';
 
 
+mkdir $tmpdir;
 mkdir "$tmpdir/a";
 mkdir "$tmpdir/a";
 mkdir "$tmpdir/a/b";
 mkdir "$tmpdir/a/b";
 mkdir "$tmpdir/a/b/c";
 mkdir "$tmpdir/a/b/c";

+ 1 - 1
scripts/t/900_update_alternatives.t

@@ -21,7 +21,7 @@ use strict;
 use warnings;
 use warnings;
 
 
 my $srcdir = $ENV{srcdir} || '.';
 my $srcdir = $ENV{srcdir} || '.';
-my $tmpdir = 't.tmp';
+my $tmpdir = 't.tmp/900_update_alternatives';
 my $admindir = File::Spec->rel2abs("$tmpdir/admindir"),
 my $admindir = File::Spec->rel2abs("$tmpdir/admindir"),
 my $altdir = File::Spec->rel2abs("$tmpdir/alternatives");
 my $altdir = File::Spec->rel2abs("$tmpdir/alternatives");
 my $bindir = File::Spec->rel2abs("$tmpdir/bin");
 my $bindir = File::Spec->rel2abs("$tmpdir/bin");