5 use Support::Templates;
6 use Support::TestSetup;
11 use Template::Provider;
12 use Test::More tests => ( scalar(@referenced_files));
14 my $template_path = 'templates/webpages/';
16 my $provider = Template::Provider->new(Support::TestSetup::template_config());
18 foreach my $ref (@Support::Templates::referenced_files) {
19 my $file = "${template_path}${ref}.html";
20 my ($result, $not_ok) = $provider->fetch($file);
23 ok(1, "${file} does not contain errors");
25 } elsif (ref($result) eq 'Template::Exception') {
26 print STDERR $result->as_string;
27 ok(0, "${file} contains syntax errors");
30 die "Unknown result type: " . ref($result);