Skip to content

Standardize code style - #6137

Merged
Naktibalda merged 9 commits into
Codeception:5.0from
TavoNiievez:5.0-php-standards
Mar 11, 2021
Merged

Naktibalda merged 9 commits into
Codeception:5.0from
TavoNiievez:5.0-php-standards

Conversation

@TavoNiievez

Copy link
Copy Markdown
Member

With this PR I do a general review of my previous PRs, and I make sure to fix any inadvertently omitted changes, in addition to taking the opportunity to give (the much desired) consistency to the source code:

  • Removed unnecessary typing docblocks
  • Standardize # as PREG delimiter in regex
  • Add {} to interpolate variables inside strings
  • Stop using list() in favor of []
  • Add strict comparisons
  • Add JSON_THROW_ON_ERROR to json functions where missing
  • Initialize properties that do not get initial value in constructor, but are typed
  • Type constants
  • Use pre-increment and pre-decrement instead of increment and decrement
  • Remove invalid type annotations
  • Fix naming
  • assertNull instead of assertSame(null, ...)

This is the last PR from me before the 5.0 release.

@TavoNiievez TavoNiievez added the 5.0 label Mar 7, 2021
@TavoNiievez
TavoNiievez requested a review from Naktibalda March 7, 2021 22:29
Comment thread src/Codeception/Command/Run.php Resolved
Comment thread src/Codeception/Test/Loader/Gherkin.php Resolved
@TavoNiievez
TavoNiievez requested a review from Naktibalda March 8, 2021 17:04
Comment thread src/Codeception/Event/SuiteEvent.php Resolved
Comment thread src/Codeception/Event/SuiteEvent.php Resolved
Comment thread src/Codeception/Lib/Di.php Resolved
Comment thread src/Codeception/Scenario.php Resolved
Comment thread src/Codeception/SuiteManager.php Resolved
Comment thread src/Codeception/SuiteManager.php Resolved
Comment thread src/Codeception/Application.php Resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants