Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CS rules: tweak array rules for test files
Test files often use data providers (or should). Data providers are provided as arrays (as `yield` is not supported in the minimum supported PHP version of PHPCS). As things were, single item arrays would be forced to be single-line, while multi-item arrays would be forced to be multi-line. For large data provider arrays which have a mix of single item and multi-item sub-arrays, this decreases the scannability of the test cases. For that reason, I'm disabling the enforcement of "single item arrays should be single line" for all test files. In practice this means that multi-item arrays still need to be multi-line, but that single item arrays can be either single line or multi-line, whichever is best for readability of the test data. Related to 155
- Loading branch information