[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[Git][lintian/lintian][master] Suggest solution for tests without purpose



Title: GitLab

Louis-Philippe Véronneau pushed to branch master at lintian / lintian

Commits:

  • 0d521eb7
    by Emanuele Rocca at 2025-09-27T15:59:08+00:00
    Suggest solution for tests without purpose
    
    When adding a new test, it took me a while to find out that tests are
    considered with no known purpose if they do not specify any expected results in
    eval/hints, or a `Test-Against` field in eval/desc.
    
    Explicitly suggest the solution if the problem is detected.
    

1 changed file:

Changes:

  • t/scripts/harness/diagnostic-value.t
    ... ... @@ -83,7 +83,9 @@ my $missing = scalar @undeclared;
    83 83
     my $total = scalar @testpaths;
    
    84 84
     diag "$missing tests out of $total have no declared diagnostic value.";
    
    85 85
     
    
    86
    -diag "Test with unknown purpose: $_" for @undeclared;
    
    86
    +diag
    
    87
    +"Test with unknown purpose: $_.\nAdd expected results to eval/hints, or 'Test-Against' to eval/desc\nSee also: t/recipes/README."
    
    88
    +  for @undeclared;
    
    87 89
     
    
    88 90
     my $exceptions = List::Compare->new(\@undeclared, \@known_undeclared);
    
    89 91
     my @unknown = $exceptions->get_Lonly;
    


  • Reply to: