Author: djpig
Date: 2005-09-21 21:57:02 +0200 (Wed, 21 Sep 2005)
New Revision: 491

Modified:
   trunk/testset/runtests
Log:
Handle tags in new format gracefully


Modified: trunk/testset/runtests
===================================================================
--- trunk/testset/runtests      2005-09-21 19:55:48 UTC (rev 490)
+++ trunk/testset/runtests      2005-09-21 19:57:02 UTC (rev 491)
@@ -106,6 +106,7 @@
 
 use lib "$ENV{'LINTIAN_ROOT'}/lib";
 use Util;
+use Tags;
 
 # --- Set the ways to call lintian and dpkg-buildpackage
 my $lintian_options = '-I';
@@ -137,13 +138,18 @@
                print "E: test-has-no-info $i->{'tag'} in $desc_file\n";
                $testok = 0;
            }
-           if (not exists $i->{'type'}) {
+           if (!exists($i->{'type'})
+               && !exists($i->{'severity'})) {
+               use Data::Dumper;
+               print Dumper $i;
                print "E: test-has-no-type $i->{'tag'} in $desc_file\n";
                $testok = 0;
                next;
            }
+
            $tags{$i->{'tag'}}{'desc_file'} = $desc_file;
-           $tags{$i->{'tag'}}{'desc_type'} = $i->{'type'};
+           $tags{$i->{'tag'}}{'desc_type'} = $i->{'type'} ||
+               $Tags::sev_to_type[$i->{'severity'}];
        }
     }
 }


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to