False Positive: Magento2.Legacy.InstallUpgrade.ObsoleteInstallDataScript
dfelton opened this issue · 1 comments
dfelton commented
Preconditions
- Package contains data patch
\VendorName\ModuleName\Setup\Patch\Data\InstallData(exact nature of data patch irrelevant)
Steps to reproduce
- Run the coding standard against the file
Setup/Patch/Data/InstallData.php
Expected result
- Sniff
Magento2.Legacy.InstallUpgrade.ObsoleteInstallDataScriptto not be triggered by the presence of a data patch namedInstallData, as it is not aSetup/InstallData.phpscript.
Actual result
- Data patch fails due to
Magento2.Legacy.InstallUpgrade.ObsoleteInstallDataScriptsniff.
Misc Notes:
- Possible to disable failure with
phpcs:ignore Magento2.Legacy.InstallUpgrade.ObsoleteInstallDataScriptannotation within the file. Line must be present on line 1, after the opening PHP tag.
m2-assistant commented
Hi @dfelton. Thank you for your report.
To speed up processing of this issue, make sure that you provided sufficient information.
Add a comment to assign the issue: @magento I am working on this
- Join Magento Community Engineering Slack and ask your questions in #github channel.