From c67d218cef155fe48107388d641072f7bdb33bf9 Mon Sep 17 00:00:00 2001 From: Axel Beckert Date: Fri, 16 Jul 2010 17:52:34 +0200 Subject: [PATCH] Tighten t/quoted-strings.t a little bit against false positives --- t/quoted-strings.t | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/t/quoted-strings.t b/t/quoted-strings.t index 0e82d50..4063118 100755 --- a/t/quoted-strings.t +++ b/t/quoted-strings.t @@ -1,6 +1,7 @@ #!/usr/bin/perl -w # -# Test that every bash script using variables uses " not '. +# Test that every bash script using variables uses " not ' around the +# variable. # # Steve # -- @@ -71,7 +72,7 @@ sub checkFile next if ( $line =~ /grep|sed|echo|awk|find|policy-rc.d|chroot|logMessage/ ); if ( $line =~ /\$/ ) { - ok( $line !~ /\'/, "Non-masked line '$line' in '$file'" ); + ok( $line !~ /\'.*\$\.*\'/, "Non-masked line '$line' in '$file'" ); } } close( FILE );