Skip to content

PHP Syntax errors in xml files #265

Closed
@Hexmage

Description

@Hexmage

Preconditions

  1. magento/magento-coding-standard v9
  2. A magento module that has an xml file that starts with <?xml version="1.0" ?>

Steps to reproduce

  1. run bin/phpcs ./ --standard=Magento2 --severity=10

Expected result

  1. Nothing module passes the test

Actual result

FILE: /opt/atlassian/pipelines/agent/build/etc/module.xml
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
 1 | ERROR | PHP syntax error: syntax error, unexpected 'version'
   |       | (T_STRING)
----------------------------------------------------------------------
FILE: /opt/atlassian/pipelines/agent/build/etc/di.xml
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
 1 | ERROR | PHP syntax error: syntax error, unexpected 'version'
   |       | (T_STRING)
----------------------------------------------------------------------

This bug got introduced in v9 because our pipelines were running v8 yesterday and didn't have this issue at the time.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions