Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CS] Update config for php-cs-fixer v2.0 and remove StyleCI config/badge #992

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
29 changes: 2 additions & 27 deletions .php_cs
Expand Up @@ -12,42 +12,17 @@ EOF;
$config = PhpCsFixer\Config::create()
->setRiskyAllowed(true)
->setRules([
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to obey the cs rules defined here, in this file, itself. :-) Change to long array syntax here, and elsewhere in the file where short array syntax is used.

//'@PHP56Migration' => true,
'@Symfony' => true,
//'@Symfony:risky' => true,
//'align_multiline_comment' => true,
'array_syntax' => ['syntax' => 'long'],
//'blank_line_before_statement' => true,
'combine_consecutive_unsets' => true,
'linebreak_after_opening_tag' => true,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line (18), as well as line 22, 23, and 24 are indented using \t (tab) characters. Please ensure the whole document is written out using spaces.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just corrected it through the web interface

// one should use PHPUnit methods to set up expected exception instead of annotations
//'general_phpdoc_annotation_remove' => ['annotations' => ['expectedException', 'expectedExceptionMessage', 'expectedExceptionMessageRegExp']],
'header_comment' => ['header' => $header],
//'heredoc_to_nowdoc' => true,
'list_syntax' => ['syntax' => 'long'],
//'method_argument_space' => ['ensure_fully_multiline' => true],
//'no_extra_consecutive_blank_lines' => ['tokens' => ['break', 'continue', 'extra', 'return', 'throw', 'use', 'parenthesis_brace_block', 'square_brace_block', 'curly_brace_block']],
//'no_null_property_initialization' => true,
'no_short_echo_tag' => true,
//'no_superfluous_elseif' => true,
//'no_unneeded_curly_braces' => true,
//'no_unneeded_final_method' => true,
//'no_unreachable_default_argument_value' => true,
//'no_useless_else' => true,
//'no_useless_return' => true,
//'ordered_class_elements' => true,
'ordered_imports' => true,
'php_unit_construct' => true,
'ordered_imports' => true,
'php_unit_construct' => true,
'php_unit_dedicate_assert' => true,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indentation error.

//'php_unit_strict' => true,
//'php_unit_test_class_requires_covers' => true,
//'phpdoc_add_missing_param_annotation' => true,
'phpdoc_order' => true,
//'phpdoc_types_order' => true,
//'semicolon_after_instruction' => true,
//'single_line_comment_style' => true,
//'strict_comparison' => true,
//'strict_param' => true,
])
->setFinder(
PhpCsFixer\Finder::create()
Expand Down