Skip to content

Commit

Permalink
update list of rules
Browse files Browse the repository at this point in the history
  • Loading branch information
keradus committed Jan 24, 2021
1 parent 688964a commit 5ad2981
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions tests/Test/AbstractFixerTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -296,16 +296,21 @@ public function testFixerUseInsertSlicesWhenOnlyInsertionsArePerformed()
if ([] === $nonAllowedMethods) {
$fixerName = $this->fixer->getName();
if (\in_array($fixerName, [
// DO NOT add anything to this list, it may be only reduced
// DO NOT add anything to this list at ease, align with core contributors whether it makes sense to insert tokens individually or by bulk for your case.
// The original list of the fixers being exceptions and insert tokens individually came from legacy reasons when it was the only available methods to insert tokens.
'blank_line_after_namespace',
'blank_line_after_opening_tag',
'blank_line_before_statement',
'class_attributes_separation',
'date_time_immutable',
'declare_strict_types',
'doctrine_annotation_braces',
'doctrine_annotation_spaces',
'final_internal_class',
'final_public_method_for_abstract_class',
'function_typehint_space',
'heredoc_indentation',
'method_chaining_indentation',
'native_constant_invocation',
'new_with_braces',
'no_short_echo_tag',
Expand All @@ -314,17 +319,17 @@ public function testFixerUseInsertSlicesWhenOnlyInsertionsArePerformed()
'php_unit_internal_class',
'php_unit_no_expectation_annotation',
'php_unit_set_up_tear_down_visibility',
'php_unit_size_class',
'php_unit_test_annotation',
'php_unit_test_class_requires_covers',
'phpdoc_to_param_type',
'phpdoc_to_return_type',
'random_api_migration',
'semicolon_after_instruction',
'single_line_after_imports',
'static_lambda',
'strict_param',
'void_return',
'class_attributes_separation',
'method_chaining_indentation',
], true)) {
static::markTestIncomplete(sprintf('Fixer "%s" may be optimized to use `Tokens::insertSlices` instead of `%s`, please help and optimize it.', $fixerName, implode(', ', $allowedMethods)));
}
Expand Down

0 comments on commit 5ad2981

Please sign in to comment.