~allison/ubuntu/raring/libsvn-web-perl/fix-for-1106378

« back to all changes in this revision

Viewing changes to t/3svnweb-install.t

  • Committer: Package Import Robot
  • Author(s): Hilko Bengen
  • Date: 2012-10-22 21:08:14 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20121022210814-5wru25mlw6dakkr8
Tags: 0.63-1
* New Upstream version
* Updated dependencies
* Switched to Debhelper 8
* Set locale for running tests

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
use warnings;
4
4
use strict;
5
5
 
6
 
use Test::More tests => 6;
 
6
use Test::More tests => 3;
7
7
use Cwd;
8
8
use File::Temp qw(tempdir);
9
9
use YAML ();
10
10
 
11
11
# Make sure that it compiles cleanly
12
 
system $^X, qw(-Iblib/lib -c bin/svnweb-install);
 
12
system "$^X -Iblib/lib -c bin/svnweb-install 2>/dev/null";
13
13
is($? >> 8, 0, 'svnweb-install compiled cleanly');
14
14
 
15
15
# Run in a temporary directory, verify that the generated config.yaml parses
19
19
 
20
20
system "$^X -I$cwd/blib/lib $cwd/bin/svnweb-install > /dev/null";
21
21
 
22
 
foreach my $file (qw(config.yaml index.cgi)) {
 
22
for my $file (qw(config.yaml)) {
23
23
    ok(-f "$tmpdir/$file", "$tmpdir/$file created");
24
24
}
25
25
 
26
 
foreach my $dir (qw(css template)) {
27
 
    ok(-d "$tmpdir/$dir", "$tmpdir/$dir/ created");
28
 
}
29
 
 
30
26
my $config;
31
27
$config = eval { YAML::LoadFile('config.yaml'); };
32
28
ok(defined $config, "YAML::LoadFile('$tmpdir/config.yaml') succeeded");
 
29
 
 
30
chdir($cwd);