summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2011-03-02 19:49:44 +0100
committerDaniel Friesel <derf@finalrewind.org>2011-03-02 19:49:44 +0100
commit6905ea23a80deb6b83937637c9e621038d9411d9 (patch)
tree0b51d4bc6bbac0a009bb5ab2c9b98ad9c8120a41
parent37e21a2515a4b80ee661a2422204cfc42faf927b (diff)
Update App::Dthumb filenames, add initial App::Dthumb test
-rwxr-xr-xlib/App/Dthumb.pm4
-rwxr-xr-xt/20-app-dthumb.t13
2 files changed, 15 insertions, 2 deletions
diff --git a/lib/App/Dthumb.pm b/lib/App/Dthumb.pm
index 365eaba..49f4783 100755
--- a/lib/App/Dthumb.pm
+++ b/lib/App/Dthumb.pm
@@ -137,7 +137,7 @@ sub new {
height => $conf{size} * $conf{spacing} . 'px',
);
- $ref->{html} = $ref->{data}->get('html_start');
+ $ref->{html} = $ref->{data}->get('html_start.dthumb');
return bless($ref, $obj);
}
@@ -337,7 +337,7 @@ Write the cached HTML data to F<index.xhtml>.
sub write_out_html {
my ($self) = @_;
- $self->{html} .= $self->{data}->get('html_end');
+ $self->{html} .= $self->{data}->get('html_end.dthumb');
open(my $fh, '>', $self->{config}->{file_index});
print {$fh} $self->{html};
diff --git a/t/20-app-dthumb.t b/t/20-app-dthumb.t
new file mode 100755
index 0000000..9a81d0b
--- /dev/null
+++ b/t/20-app-dthumb.t
@@ -0,0 +1,13 @@
+#!/usr/bin/env perl
+use strict;
+use warnings;
+use 5.010;
+use autodie;
+
+use Test::More tests => 2;
+
+use_ok('App::Dthumb');
+
+my $dthumb = App::Dthumb->new();
+
+isa_ok($dthumb, 'App::Dthumb');