Skip to content

Hooks logic fails for short array syntax #358

@GaryJones

Description

@GaryJones

Changing to short array syntax in Tests/Hooks/AlwaysReturnInFilterUnitTests.inc and Tests/Hooks/PreGetPostsUnitTests.inc result in those tests failing.

It suggests that some of the processing logic in each sniff is flawed for short array syntaxes.

Both long and short array syntax should be retained in the unit tests.

Environment

Use php -v and composer show to get versions.

Question Answer
PHP version 7.2.0
PHP_CodeSniffer version 3.4.0
VIPCS version master

Tested Against master branch?

  • I have verified the issue still exists in the master branch of VIPCS.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions