From b0ed284b54d16cec611e28590a73be136aa49e67 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Fri, 11 Apr 2014 18:49:07 +0000 Subject: [PATCH] [PASSED QA] Bug 12076: better detect an untranslatable template construct Per bug 6458, template constructs of the form
  • [2] Run prove -v xt/tt_valid.t. Note that no error is reported. [3] Apply the patch, and rerun the tt_valid.t test. This time, an error should be reported. Signed-off-by: Galen Charlton Signed-off-by: Bernardo Gonzalez Kriegel Works well, detects the forbidden pattern No koha-qa errors. Signed-off-by: Katrin Fischer Works as described, passes all tests and QA script. --- xt/tt_valid.t | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xt/tt_valid.t b/xt/tt_valid.t index f71085e..e33b760 100755 --- a/xt/tt_valid.t +++ b/xt/tt_valid.t @@ -38,7 +38,7 @@ my @files_with_directive_in_tag = do { while ( my $token = $parser->next_token ) { my $attr = $token->{_attr}; next unless $attr; - push @lines, $token->{_lc} if $attr->{'[%'}; + push @lines, $token->{_lc} if $attr->{'[%'} or $attr->{'[%-'}; } ($dir) = $dir =~ /koha-tmpl\/(.*)$/; push @files, { name => "$dir/$name", lines => \@lines } if @lines; -- 1.8.3.2