Unverified Commit 4f8de00c authored by Mitch Portier's avatar Mitch Portier Committed by GitHub
Browse files

tests(phpstan): Remove ignored rules that have been fixed in PHPStan and remove unused code

parent 1fe6495d
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -237,10 +237,6 @@ class FunctionCommentSniff implements Sniff
                    $typeNames      = explode('|', $type);
                    $suggestedNames = [];
                    $hasNull        = false;
                    $hasMultiple    = false;
                    if (count($typeNames) > 0) {
                        $hasMultiple = true;
                    }

                    foreach ($typeNames as $i => $typeName) {
                        if (strtolower($typeName) === 'null') {
+1 −1
Original line number Diff line number Diff line
@@ -28,6 +28,6 @@
    },
    "require-dev": {
        "phpunit/phpunit": "^6.0 || ^7.0",
        "phpstan/phpstan": "^0.12.50"
        "phpstan/phpstan": "^0.12.51"
    }
}
+0 −16
Original line number Diff line number Diff line
@@ -57,19 +57,3 @@ parameters:
            path: coder_sniffer/Drupal/Sniffs/Semantics/FunctionCall.php
        # False positive: Variable $a in isset() always exists and is not
        # nullable. https://github.com/phpstan/phpstan/issues/2816
        -
            count: 2
            message: '~^Variable \$fileShort in isset\(\) always exists and is not nullable.$~'
            path: coder_sniffer/Drupal/Sniffs/Commenting/DocCommentSniff.php
        -
            message: "#^Result of && is always false\\.$#"
            count: 2
            path: coder_sniffer/Drupal/Sniffs/Commenting/DocCommentSniff.php
        -
            message: "#^Else branch is unreachable because previous condition is always true\\.$#"
            count: 1
            path: coder_sniffer/Drupal/Sniffs/Commenting/FunctionCommentSniff.php
        -
            message: "#^Strict comparison using \\=\\=\\= between true and false will always evaluate to false\\.$#"
            count: 1
            path: coder_sniffer/Drupal/Sniffs/Commenting/DocCommentSniff.php