summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2011-05-18 18:20:37 +0200
committerDaniel Friesel <derf@finalrewind.org>2011-05-18 18:20:37 +0200
commit18819b75b20c3a8b3bf7a0b6120c6805c265fd60 (patch)
tree0c84cbe97552809288cb9a8067d0c50968d4beab
parent65de69067277479c3f8e011098ca4ce70df8267a (diff)
Add test for recent add_file fix
-rw-r--r--t/29-app-hashl.t9
1 files changed, 8 insertions, 1 deletions
diff --git a/t/29-app-hashl.t b/t/29-app-hashl.t
index fd8f95b..f17fc88 100644
--- a/t/29-app-hashl.t
+++ b/t/29-app-hashl.t
@@ -3,7 +3,7 @@ use strict;
use warnings;
use 5.010;
-use Test::More tests => 31;
+use Test::More tests => 32;
use_ok('App::Hashl');
@@ -77,6 +77,13 @@ unlink('t/in/hashl.db');
is($hashl->file_in_db('t/in/4'), $IGNORED, 'file still ignored');
is_deeply([$hashl->files()], [], 'no files in db');
+$hashl->add_file(
+ file => 't/in/1k',
+ path => 't/in/1k',
+);
+
+is_deeply([$hashl->files()], [], 'ignored file not added');
+
undef $hashl;
my $hash_512 = App::Hashl->new(read_size => 512)->hash_file('t/in/1k');