From 84e4c426efc00b9b2a67687af8b3225277911d30 Mon Sep 17 00:00:00 2001 From: Daniel Siepmann Date: Tue, 9 May 2017 12:12:46 +0200 Subject: [PATCH] TASK: Update InlineCommentSniff tests to reflect added removed extension Relates: #44 --- .../InlineCommentSniff/Expected.diff | 4 +- .../InlineCommentSniff/Expected.json | 40 ++++++++++++++++++- .../InlineCommentSniff/InputFileForIssues.php | 12 ++++++ 3 files changed, 52 insertions(+), 4 deletions(-) diff --git a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.diff b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.diff index 5f59195..57d888b 100644 --- a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.diff +++ b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.diff @@ -19,5 +19,5 @@ - // @var Tx_Extbase_Command_HelpCommandController $variable + // @var \TYPO3\CMS\Extbase\Command\HelpCommandController $variable $variable; - } - } + + /* @var $variable TYPO3\CMS\Perm\Controller\PermissionAjaxController */ diff --git a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.json b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.json index 2a6f3ab..580e6d2 100644 --- a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.json +++ b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/Expected.json @@ -38,14 +38,50 @@ "severity": 5, "source": "Typo3Update.Classname.InlineComment.legacyClassname", "type": "ERROR" + }, + { + "column": 9, + "fixable": false, + "line": 38, + "message": "Calls to removed code are not allowed; found perm. Removed in 7.0. The logic is moved into EXT:beuser. See: https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.0/Breaking-62339-MoveExtPermIntoExtBeuser.html", + "severity": 5, + "source": "Typo3Update.Classname.InlineComment.RemovedExtension.perm", + "type": "WARNING" + }, + { + "column": 9, + "fixable": false, + "line": 41, + "message": "Calls to removed code are not allowed; found perm. Removed in 7.0. The logic is moved into EXT:beuser. See: https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.0/Breaking-62339-MoveExtPermIntoExtBeuser.html", + "severity": 5, + "source": "Typo3Update.Classname.InlineComment.RemovedExtension.perm", + "type": "WARNING" + }, + { + "column": 9, + "fixable": false, + "line": 44, + "message": "Calls to removed code are not allowed; found perm. Removed in 7.0. The logic is moved into EXT:beuser. See: https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.0/Breaking-62339-MoveExtPermIntoExtBeuser.html", + "severity": 5, + "source": "Typo3Update.Classname.InlineComment.RemovedExtension.perm", + "type": "WARNING" + }, + { + "column": 9, + "fixable": false, + "line": 47, + "message": "Calls to removed code are not allowed; found perm. Removed in 7.0. The logic is moved into EXT:beuser. See: https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.0/Breaking-62339-MoveExtPermIntoExtBeuser.html", + "severity": 5, + "source": "Typo3Update.Classname.InlineComment.RemovedExtension.perm", + "type": "WARNING" } ], - "warnings": 0 + "warnings": 4 } }, "totals": { "errors": 4, "fixable": 4, - "warnings": 0 + "warnings": 4 } } diff --git a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/InputFileForIssues.php b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/InputFileForIssues.php index eedd2f8..47ffde1 100644 --- a/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/InputFileForIssues.php +++ b/tests/Fixtures/Standards/Typo3Update/Sniffs/Classname/InlineCommentSniff/InputFileForIssues.php @@ -34,5 +34,17 @@ class InputFileForIssues // @var Tx_Extbase_Command_HelpCommandController $variable $variable; + + /* @var $variable TYPO3\CMS\Perm\Controller\PermissionAjaxController */ + $variable; + + // @var $variable \TYPO3\CMS\Perm\Controller\PermissionAjaxController + $variable; + + /* @var \TYPO3\CMS\Perm\Controller\PermissionAjaxController $variable */ + $variable; + + // @var TYPO3\CMS\Perm\Controller\PermissionAjaxController $variable + $variable; } }