Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File::addMessage(): do not ignore Internal errors when scanning selectively #3915

Closed
wants to merge 2 commits into from

Commits on Oct 31, 2023

  1. ErrorSuppressionTest: prevent Internal errors

    ... about a mismatch in line endings when the code "template" is defined using a heredoc with Linux line endings, while the code snippets being inserted into the code "template" were using line endings matching the OS on which the tests were being run.
    jrfnl committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    7126fad View commit details
    Browse the repository at this point in the history
  2. File::addMessage(): do not ignore Internal errors when scanning sel…

    …ectively
    
    When either the `--sniffs=...` CLI parameter is used, or the `--exclude=...` CLI parameter, the `File::addMessage()` method bows out when an error is passed which is not for one of the selected sniffs/is for one of the excluded sniffs.
    
    Unfortunately, this "bowing out" did not take `Internal` errors into account, meaning those were now hidden, while those should _always_ be thrown as they generally inform the end-user of something seriously wrong (mixed line endings/no code found etc).
    
    Fixed now.
    
    Includes updating two test files to allow for seeing internal errors.
    jrfnl committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    0a2d7f1 View commit details
    Browse the repository at this point in the history