Bump version to 2.1.1
[gnu-stow.git] / t / defer.t
blobca47fb308aa851f12862164945ff621c39ad8eec
1 #!/usr/local/bin/perl
4 # Testing defer().
7 use strict;
8 use warnings;
10 use testutil;
12 use Test::More tests => 4;
14 init_test_dirs();
15 cd("$OUT_DIR/target");
17 my $stow;
19 $stow = new_Stow(defer => [ 'man' ]);
20 ok($stow->defer('man/man1/file.1') => 'simple success');
22 $stow = new_Stow(defer => [ 'lib' ]);
23 ok(! $stow->defer('man/man1/file.1') => 'simple failure');
25 $stow = new_Stow(defer => [ 'lib', 'man', 'share' ]);
26 ok($stow->defer('man/man1/file.1') => 'complex success');
28 $stow = new_Stow(defer => [ 'lib', 'man', 'share' ]);
29 ok(! $stow->defer('bin/file') => 'complex failure');