From 3aea20b9e0c71deac51b50eeb7a517e094a474fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=B6ller?= Date: Thu, 8 Oct 2020 19:50:46 +0200 Subject: [PATCH] Enhancement: Implement RuleSet\Php74 for use with PHP 7.4 --- CHANGELOG.md | 15 +- README.md | 1 + src/RuleSet/Php74.php | 345 +++++++++++++++++++++++++++++++ test/Unit/RuleSet/Php74Test.php | 351 ++++++++++++++++++++++++++++++++ 4 files changed, 710 insertions(+), 2 deletions(-) create mode 100644 src/RuleSet/Php74.php create mode 100644 test/Unit/RuleSet/Php74Test.php diff --git a/CHANGELOG.md b/CHANGELOG.md index dc76b70d..de9fe1f1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,15 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), ## Unreleased -For a full diff see [`2.2.2...main`][2.2.2...main]. +For a full diff see [`2.3.0...main`][2.3.0...main]. + +## [`2.3.0`][2.3.0] + +For a full diff see [`2.2.2...2.3.0`][2.2.2...2.3.0]. + +### Added + +* Added `RuleSet\Php74` for use with PHP 7.4 ([#200]), by [@dependabot] ## [`2.2.2`][2.2.2] @@ -94,6 +102,7 @@ For a full diff see [`d899e77...1.0.0`][d899e77...1.0.0]. [2.2.0]: https://github.com/ergebnis/php-cs-fixer-config/releases/tag/2.2.0 [2.2.1]: https://github.com/ergebnis/php-cs-fixer-config/releases/tag/2.2.1 [2.2.2]: https://github.com/ergebnis/php-cs-fixer-config/releases/tag/2.2.2 +[2.3.0]: https://github.com/ergebnis/php-cs-fixer-config/releases/tag/2.3.0 [d899e77...1.0.0]: https://github.com/ergebnis/php-cs-fixer-config/compare/d899e77...1.0.0 [1.0.0...1.1.0]: https://github.com/ergebnis/php-cs-fixer-config/compare/1.0.0...1.1.0 @@ -105,7 +114,8 @@ For a full diff see [`d899e77...1.0.0`][d899e77...1.0.0]. [2.1.2...2.2.0]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.1.2...2.2.0 [2.2.0...2.2.1]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.2.0...2.2.1 [2.2.1...2.2.2]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.2.1...2.2.2 -[2.2.2...main]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.2.2...main +[2.2.2...2.3.0]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.2.1...2.3.0 +[2.3.0...main]: https://github.com/ergebnis/php-cs-fixer-config/compare/2.3.0...main [#3]: https://github.com/ergebnis/php-cs-fixer-config/pull/3 [#14]: https://github.com/ergebnis/php-cs-fixer-config/pull/14 @@ -116,6 +126,7 @@ For a full diff see [`d899e77...1.0.0`][d899e77...1.0.0]. [#133]: https://github.com/ergebnis/php-cs-fixer-config/pull/133 [#135]: https://github.com/ergebnis/php-cs-fixer-config/pull/135 [#168]: https://github.com/ergebnis/php-cs-fixer-config/pull/168 +[#200]: https://github.com/ergebnis/php-cs-fixer-config/pull/200 [@dependabot]: https://github.com/apps/dependabot [@linuxjuggler]: https://github.com/linuxjuggler diff --git a/README.md b/README.md index 59169abc..48e347fd 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,7 @@ Pick one of the rule sets: * [`Ergebnis\PhpCsFixer\RuleSet\Laravel6`](src/RuleSet/Laravel6.php) * [`Ergebnis\PhpCsFixer\RuleSet\Php71`](src/RuleSet/Php71.php) * [`Ergebnis\PhpCsFixer\RuleSet\Php73`](src/RuleSet/Php73.php) +* [`Ergebnis\PhpCsFixer\RuleSet\Php74`](src/RuleSet/Php74.php) Create a configuration file `.php_cs` in the root of your project: diff --git a/src/RuleSet/Php74.php b/src/RuleSet/Php74.php new file mode 100644 index 00000000..8ecfe9ee --- /dev/null +++ b/src/RuleSet/Php74.php @@ -0,0 +1,345 @@ + true, + 'align_multiline_comment' => [ + 'comment_type' => 'all_multiline', + ], + 'array_indentation' => true, + 'array_syntax' => [ + 'syntax' => 'short', + ], + 'backtick_to_shell_exec' => true, + 'binary_operator_spaces' => [ + 'default' => 'single_space', + ], + 'blank_line_after_opening_tag' => true, + 'blank_line_before_return' => false, + 'blank_line_before_statement' => [ + 'statements' => [ + 'break', + 'continue', + 'declare', + 'default', + 'die', + 'do', + 'exit', + 'for', + 'foreach', + 'goto', + 'if', + 'include', + 'include_once', + 'require', + 'require_once', + 'return', + 'switch', + 'throw', + 'try', + 'while', + 'yield', + ], + ], + 'cast_spaces' => true, + 'class_attributes_separation' => [ + 'elements' => [ + 'method', + ], + ], + 'class_keyword_remove' => false, + 'combine_consecutive_issets' => true, + 'combine_consecutive_unsets' => true, + 'combine_nested_dirname' => true, + 'comment_to_phpdoc' => true, + 'compact_nullable_typehint' => true, + 'concat_space' => [ + 'spacing' => 'one', + ], + 'date_time_immutable' => true, + 'declare_equal_normalize' => true, + 'declare_strict_types' => true, + 'dir_constant' => true, + 'doctrine_annotation_array_assignment' => [ + 'operator' => ':', + ], + 'doctrine_annotation_braces' => [ + 'syntax' => 'without_braces', + ], + 'doctrine_annotation_indentation' => true, + 'doctrine_annotation_spaces' => [ + 'after_argument_assignments' => false, + 'after_array_assignments_colon' => true, + 'after_array_assignments_equals' => false, + 'around_parentheses' => true, + 'before_argument_assignments' => false, + 'before_array_assignments_colon' => false, + 'before_array_assignments_equals' => false, + ], + 'ereg_to_preg' => true, + 'error_suppression' => [ + 'mute_deprecation_error' => true, + 'noise_remaining_usages' => true, + ], + 'escape_implicit_backslashes' => true, + 'explicit_indirect_variable' => true, + 'explicit_string_variable' => true, + 'final_class' => true, + 'final_internal_class' => true, + 'final_public_method_for_abstract_class' => true, + 'final_static_access' => true, + 'fopen_flag_order' => true, + 'fopen_flags' => true, + 'fully_qualified_strict_types' => true, + 'function_to_constant' => true, + 'function_typehint_space' => true, + 'general_phpdoc_annotation_remove' => false, + 'global_namespace_import' => false, + 'hash_to_slash_comment' => true, + 'header_comment' => false, + 'heredoc_indentation' => true, + 'heredoc_to_nowdoc' => true, + 'implode_call' => true, + 'include' => true, + 'increment_style' => [ + 'style' => 'pre', + ], + 'is_null' => true, + 'linebreak_after_opening_tag' => true, + 'list_syntax' => [ + 'syntax' => 'short', + ], + 'logical_operators' => true, + 'lowercase_cast' => true, + 'lowercase_constants' => false, + 'lowercase_static_reference' => true, + 'magic_constant_casing' => true, + 'magic_method_casing' => true, + 'mb_str_functions' => true, + 'method_argument_space' => [ + 'ensure_fully_multiline' => true, + 'keep_multiple_spaces_after_comma' => false, + ], + 'method_chaining_indentation' => true, + 'method_separation' => false, + 'modernize_types_casting' => true, + 'multiline_comment_opening_closing' => true, + 'multiline_whitespace_before_semicolons' => [ + 'strategy' => 'no_multi_line', + ], + 'native_constant_invocation' => true, + 'native_function_casing' => true, + 'native_function_invocation' => true, + 'native_function_type_declaration_casing' => true, + 'new_with_braces' => true, + 'no_alias_functions' => true, + 'no_alternative_syntax' => true, + 'no_binary_string' => true, + 'no_blank_lines_after_class_opening' => true, + 'no_blank_lines_after_phpdoc' => true, + 'no_blank_lines_before_namespace' => false, + 'no_empty_comment' => true, + 'no_empty_phpdoc' => true, + 'no_empty_statement' => true, + 'no_extra_blank_lines' => [ + 'tokens' => [ + 'break', + 'case', + 'continue', + 'curly_brace_block', + 'default', + 'extra', + 'parenthesis_brace_block', + 'return', + 'square_brace_block', + 'switch', + 'throw', + 'use', + 'use_trait', + ], + ], + 'no_extra_consecutive_blank_lines' => false, + 'no_homoglyph_names' => true, + 'no_leading_import_slash' => true, + 'no_leading_namespace_whitespace' => true, + 'no_mixed_echo_print' => [ + 'use' => 'echo', + ], + 'no_multiline_whitespace_around_double_arrow' => true, + 'no_multiline_whitespace_before_semicolons' => false, + 'no_null_property_initialization' => true, + 'no_php4_constructor' => false, + 'no_short_bool_cast' => true, + 'no_short_echo_tag' => true, + 'no_singleline_whitespace_before_semicolons' => true, + 'no_spaces_around_offset' => true, + 'no_superfluous_elseif' => true, + 'no_superfluous_phpdoc_tags' => false, + 'no_trailing_comma_in_list_call' => true, + 'no_trailing_comma_in_singleline_array' => true, + 'no_unneeded_control_parentheses' => true, + 'no_unneeded_curly_braces' => true, + 'no_unneeded_final_method' => true, + 'no_unreachable_default_argument_value' => true, + 'no_unset_cast' => true, + 'no_unset_on_property' => true, + 'no_unused_imports' => true, + 'no_useless_else' => true, + 'no_useless_return' => true, + 'no_whitespace_before_comma_in_array' => true, + 'no_whitespace_in_blank_line' => true, + 'non_printable_character' => true, + 'normalize_index_brace' => true, + 'not_operator_with_space' => false, + 'not_operator_with_successor_space' => false, + 'nullable_type_declaration_for_default_null_value' => true, + 'object_operator_without_whitespace' => true, + 'ordered_class_elements' => true, + 'ordered_imports' => [ + 'imports_order' => [ + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_CLASS, + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_CONST, + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_FUNCTION, + ], + ], + 'ordered_interfaces' => true, + 'php_unit_construct' => true, + 'php_unit_dedicate_assert' => [ + 'target' => 'newest', + ], + 'php_unit_dedicate_assert_internal_type' => true, + 'php_unit_expectation' => [ + 'target' => 'newest', + ], + 'php_unit_fqcn_annotation' => true, + 'php_unit_internal_class' => [ + 'types' => [ + 'abstract', + 'final', + 'normal', + ], + ], + 'php_unit_method_casing' => true, + 'php_unit_mock' => true, + 'php_unit_mock_short_will_return' => true, + 'php_unit_namespaced' => [ + 'target' => 'newest', + ], + 'php_unit_no_expectation_annotation' => [ + 'target' => 'newest', + 'use_class_const' => true, + ], + 'php_unit_ordered_covers' => true, + 'php_unit_set_up_tear_down_visibility' => true, + 'php_unit_size_class' => false, + 'php_unit_strict' => false, + 'php_unit_test_annotation' => true, + 'php_unit_test_case_static_method_calls' => [ + 'call_type' => 'self', + ], + 'php_unit_test_class_requires_covers' => true, + 'phpdoc_add_missing_param_annotation' => [ + 'only_untyped' => false, + ], + 'phpdoc_align' => true, + 'phpdoc_annotation_without_dot' => true, + 'phpdoc_indent' => true, + 'phpdoc_inline_tag' => true, + 'phpdoc_line_span' => [ + 'const' => 'multi', + 'method' => 'multi', + 'property' => 'multi', + ], + 'phpdoc_no_access' => true, + 'phpdoc_no_alias_tag' => true, + 'phpdoc_no_empty_return' => true, + 'phpdoc_no_package' => true, + 'phpdoc_no_useless_inheritdoc' => true, + 'phpdoc_order' => true, + 'phpdoc_return_self_reference' => true, + 'phpdoc_scalar' => true, + 'phpdoc_separation' => true, + 'phpdoc_single_line_var_spacing' => true, + 'phpdoc_summary' => true, + 'phpdoc_to_comment' => false, + 'phpdoc_to_param_type' => false, + 'phpdoc_to_return_type' => false, + 'phpdoc_trim' => true, + 'phpdoc_trim_consecutive_blank_line_separation' => true, + 'phpdoc_types' => true, + 'phpdoc_types_order' => [ + 'null_adjustment' => 'always_first', + 'sort_algorithm' => 'alpha', + ], + 'phpdoc_var_annotation_correct_order' => true, + 'phpdoc_var_without_name' => true, + 'pow_to_exponentiation' => true, + 'pre_increment' => false, + 'protected_to_private' => true, + 'psr0' => false, + 'psr4' => true, + 'random_api_migration' => true, + 'return_assignment' => true, + 'return_type_declaration' => true, + 'self_accessor' => true, + 'self_static_accessor' => true, + 'semicolon_after_instruction' => true, + 'set_type_to_cast' => true, + 'short_scalar_cast' => true, + 'silenced_deprecation_error' => false, + 'simple_to_complex_string_variable' => true, + 'simplified_null_return' => false, + 'single_blank_line_before_namespace' => true, + 'single_line_comment_style' => false, + 'single_line_throw' => false, + 'single_quote' => true, + 'single_trait_insert_per_statement' => true, + 'space_after_semicolon' => true, + 'standardize_increment' => true, + 'standardize_not_equals' => true, + 'static_lambda' => true, + 'strict_comparison' => true, + 'strict_param' => true, + 'string_line_ending' => true, + 'ternary_operator_spaces' => true, + 'ternary_to_null_coalescing' => true, + 'trailing_comma_in_multiline_array' => true, + 'trim_array_spaces' => true, + 'unary_operator_spaces' => true, + 'visibility_required' => [ + 'elements' => [ + 'const', + 'method', + 'property', + ], + ], + 'void_return' => true, + 'whitespace_after_comma_in_array' => true, + 'yoda_style' => [ + 'always_move_variable' => true, + 'equal' => true, + 'identical' => true, + 'less_and_greater' => true, + ], + ]; + + protected $targetPhpVersion = 70400; +} diff --git a/test/Unit/RuleSet/Php74Test.php b/test/Unit/RuleSet/Php74Test.php new file mode 100644 index 00000000..e1909ed8 --- /dev/null +++ b/test/Unit/RuleSet/Php74Test.php @@ -0,0 +1,351 @@ + true, + 'align_multiline_comment' => [ + 'comment_type' => 'all_multiline', + ], + 'array_indentation' => true, + 'array_syntax' => [ + 'syntax' => 'short', + ], + 'backtick_to_shell_exec' => true, + 'binary_operator_spaces' => [ + 'default' => 'single_space', + ], + 'blank_line_after_opening_tag' => true, + 'blank_line_before_return' => false, + 'blank_line_before_statement' => [ + 'statements' => [ + 'break', + 'continue', + 'declare', + 'default', + 'die', + 'do', + 'exit', + 'for', + 'foreach', + 'goto', + 'if', + 'include', + 'include_once', + 'require', + 'require_once', + 'return', + 'switch', + 'throw', + 'try', + 'while', + 'yield', + ], + ], + 'cast_spaces' => true, + 'class_attributes_separation' => [ + 'elements' => [ + 'method', + ], + ], + 'class_keyword_remove' => false, + 'combine_consecutive_issets' => true, + 'combine_consecutive_unsets' => true, + 'combine_nested_dirname' => true, + 'comment_to_phpdoc' => true, + 'compact_nullable_typehint' => true, + 'concat_space' => [ + 'spacing' => 'one', + ], + 'date_time_immutable' => true, + 'declare_equal_normalize' => true, + 'declare_strict_types' => true, + 'dir_constant' => true, + 'doctrine_annotation_array_assignment' => [ + 'operator' => ':', + ], + 'doctrine_annotation_braces' => [ + 'syntax' => 'without_braces', + ], + 'doctrine_annotation_indentation' => true, + 'doctrine_annotation_spaces' => [ + 'after_argument_assignments' => false, + 'after_array_assignments_colon' => true, + 'after_array_assignments_equals' => false, + 'around_parentheses' => true, + 'before_argument_assignments' => false, + 'before_array_assignments_colon' => false, + 'before_array_assignments_equals' => false, + ], + 'ereg_to_preg' => true, + 'error_suppression' => [ + 'mute_deprecation_error' => true, + 'noise_remaining_usages' => true, + ], + 'escape_implicit_backslashes' => true, + 'explicit_indirect_variable' => true, + 'explicit_string_variable' => true, + 'final_class' => true, + 'final_internal_class' => true, + 'final_public_method_for_abstract_class' => true, + 'final_static_access' => true, + 'fopen_flag_order' => true, + 'fopen_flags' => true, + 'fully_qualified_strict_types' => true, + 'function_to_constant' => true, + 'function_typehint_space' => true, + 'general_phpdoc_annotation_remove' => false, + 'global_namespace_import' => false, + 'hash_to_slash_comment' => true, + 'header_comment' => false, + 'heredoc_indentation' => true, + 'heredoc_to_nowdoc' => true, + 'implode_call' => true, + 'include' => true, + 'increment_style' => [ + 'style' => 'pre', + ], + 'is_null' => true, + 'linebreak_after_opening_tag' => true, + 'list_syntax' => [ + 'syntax' => 'short', + ], + 'logical_operators' => true, + 'lowercase_cast' => true, + 'lowercase_constants' => false, + 'lowercase_static_reference' => true, + 'magic_constant_casing' => true, + 'magic_method_casing' => true, + 'mb_str_functions' => true, + 'method_argument_space' => [ + 'ensure_fully_multiline' => true, + 'keep_multiple_spaces_after_comma' => false, + ], + 'method_chaining_indentation' => true, + 'method_separation' => false, + 'modernize_types_casting' => true, + 'multiline_comment_opening_closing' => true, + 'multiline_whitespace_before_semicolons' => [ + 'strategy' => 'no_multi_line', + ], + 'native_constant_invocation' => true, + 'native_function_casing' => true, + 'native_function_invocation' => true, + 'native_function_type_declaration_casing' => true, + 'new_with_braces' => true, + 'no_alias_functions' => true, + 'no_alternative_syntax' => true, + 'no_binary_string' => true, + 'no_blank_lines_after_class_opening' => true, + 'no_blank_lines_after_phpdoc' => true, + 'no_blank_lines_before_namespace' => false, + 'no_empty_comment' => true, + 'no_empty_phpdoc' => true, + 'no_empty_statement' => true, + 'no_extra_blank_lines' => [ + 'tokens' => [ + 'break', + 'case', + 'continue', + 'curly_brace_block', + 'default', + 'extra', + 'parenthesis_brace_block', + 'return', + 'square_brace_block', + 'switch', + 'throw', + 'use', + 'use_trait', + ], + ], + 'no_extra_consecutive_blank_lines' => false, + 'no_homoglyph_names' => true, + 'no_leading_import_slash' => true, + 'no_leading_namespace_whitespace' => true, + 'no_mixed_echo_print' => [ + 'use' => 'echo', + ], + 'no_multiline_whitespace_around_double_arrow' => true, + 'no_multiline_whitespace_before_semicolons' => false, + 'no_null_property_initialization' => true, + 'no_php4_constructor' => false, + 'no_short_bool_cast' => true, + 'no_short_echo_tag' => true, + 'no_singleline_whitespace_before_semicolons' => true, + 'no_spaces_around_offset' => true, + 'no_superfluous_elseif' => true, + 'no_superfluous_phpdoc_tags' => false, + 'no_trailing_comma_in_list_call' => true, + 'no_trailing_comma_in_singleline_array' => true, + 'no_unneeded_control_parentheses' => true, + 'no_unneeded_curly_braces' => true, + 'no_unneeded_final_method' => true, + 'no_unreachable_default_argument_value' => true, + 'no_unset_cast' => true, + 'no_unset_on_property' => true, + 'no_unused_imports' => true, + 'no_useless_else' => true, + 'no_useless_return' => true, + 'no_whitespace_before_comma_in_array' => true, + 'no_whitespace_in_blank_line' => true, + 'non_printable_character' => true, + 'normalize_index_brace' => true, + 'not_operator_with_space' => false, + 'not_operator_with_successor_space' => false, + 'nullable_type_declaration_for_default_null_value' => true, + 'object_operator_without_whitespace' => true, + 'ordered_class_elements' => true, + 'ordered_imports' => [ + 'imports_order' => [ + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_CLASS, + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_CONST, + Fixer\Import\OrderedImportsFixer::IMPORT_TYPE_FUNCTION, + ], + ], + 'ordered_interfaces' => true, + 'php_unit_construct' => true, + 'php_unit_dedicate_assert' => [ + 'target' => 'newest', + ], + 'php_unit_dedicate_assert_internal_type' => true, + 'php_unit_expectation' => [ + 'target' => 'newest', + ], + 'php_unit_fqcn_annotation' => true, + 'php_unit_internal_class' => [ + 'types' => [ + 'abstract', + 'final', + 'normal', + ], + ], + 'php_unit_method_casing' => true, + 'php_unit_mock' => true, + 'php_unit_mock_short_will_return' => true, + 'php_unit_namespaced' => [ + 'target' => 'newest', + ], + 'php_unit_no_expectation_annotation' => [ + 'target' => 'newest', + 'use_class_const' => true, + ], + 'php_unit_ordered_covers' => true, + 'php_unit_set_up_tear_down_visibility' => true, + 'php_unit_size_class' => false, + 'php_unit_strict' => false, + 'php_unit_test_annotation' => true, + 'php_unit_test_case_static_method_calls' => [ + 'call_type' => 'self', + ], + 'php_unit_test_class_requires_covers' => true, + 'phpdoc_add_missing_param_annotation' => [ + 'only_untyped' => false, + ], + 'phpdoc_align' => true, + 'phpdoc_annotation_without_dot' => true, + 'phpdoc_indent' => true, + 'phpdoc_inline_tag' => true, + 'phpdoc_line_span' => [ + 'const' => 'multi', + 'method' => 'multi', + 'property' => 'multi', + ], + 'phpdoc_no_access' => true, + 'phpdoc_no_alias_tag' => true, + 'phpdoc_no_empty_return' => true, + 'phpdoc_no_package' => true, + 'phpdoc_no_useless_inheritdoc' => true, + 'phpdoc_order' => true, + 'phpdoc_return_self_reference' => true, + 'phpdoc_scalar' => true, + 'phpdoc_separation' => true, + 'phpdoc_single_line_var_spacing' => true, + 'phpdoc_summary' => true, + 'phpdoc_to_comment' => false, + 'phpdoc_to_param_type' => false, + 'phpdoc_to_return_type' => false, + 'phpdoc_trim' => true, + 'phpdoc_trim_consecutive_blank_line_separation' => true, + 'phpdoc_types' => true, + 'phpdoc_types_order' => [ + 'null_adjustment' => 'always_first', + 'sort_algorithm' => 'alpha', + ], + 'phpdoc_var_annotation_correct_order' => true, + 'phpdoc_var_without_name' => true, + 'pow_to_exponentiation' => true, + 'pre_increment' => false, + 'protected_to_private' => true, + 'psr0' => false, + 'psr4' => true, + 'random_api_migration' => true, + 'return_assignment' => true, + 'return_type_declaration' => true, + 'self_accessor' => true, + 'self_static_accessor' => true, + 'semicolon_after_instruction' => true, + 'set_type_to_cast' => true, + 'short_scalar_cast' => true, + 'silenced_deprecation_error' => false, + 'simple_to_complex_string_variable' => true, + 'simplified_null_return' => false, + 'single_blank_line_before_namespace' => true, + 'single_line_comment_style' => false, + 'single_line_throw' => false, + 'single_quote' => true, + 'single_trait_insert_per_statement' => true, + 'space_after_semicolon' => true, + 'standardize_increment' => true, + 'standardize_not_equals' => true, + 'static_lambda' => true, + 'strict_comparison' => true, + 'strict_param' => true, + 'string_line_ending' => true, + 'ternary_operator_spaces' => true, + 'ternary_to_null_coalescing' => true, + 'trailing_comma_in_multiline_array' => true, + 'trim_array_spaces' => true, + 'unary_operator_spaces' => true, + 'visibility_required' => [ + 'elements' => [ + 'const', + 'method', + 'property', + ], + ], + 'void_return' => true, + 'whitespace_after_comma_in_array' => true, + 'yoda_style' => [ + 'always_move_variable' => true, + 'equal' => true, + 'identical' => true, + 'less_and_greater' => true, + ], + ]; + + protected $targetPhpVersion = 70400; +}