• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

FriendsOfPHP / PHP-CS-Fixer / 20631
93%

Build:
DEFAULT BRANCH: master
Ran 10 Apr 2020 12:20AM UTC
Jobs 1
Files 407
Run time 29s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
20631

cron

travis-ci

SpacePossum
feature #4790 ArrayPushFixer - introduction (SpacePossum)

This PR was merged into the 2.17-dev branch.

Discussion
----------

ArrayPushFixer - introduction

```
possum@aquarium:/home/possum/work/PHP-CS-Fixer$ php php-cs-fixer describe array_push
Description of array_push rule.
Converts simple usages of ``array_push($x, $y);`` to ``$x[] = $y;``.

Fixer applying this rule is risky.
Risky when the function `array_push` is overridden.

Fixing examples:
 * Example #1.
```
```diff
--- Original
+++ New
@@ -1,2 +1,2 @@
 <?php
-array_push($x, $y);
+$x[] = $y;
```

closes https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues/3483

Commits
-------

4400ea5d ArrayPushFixer - introduction

14729 of 17872 relevant lines covered (82.41%)

34.02 hits per line

Jobs
ID Job ID Ran Files Coverage
7 20631.7 (DEFAULT_COMPOSER_FLAGS="--optimize-autoloader --no-interaction --no-progress" COMPOSER_FLAGS="") 10 Apr 2020 12:18AM UTC 0
82.41
Travis Job 20631.7
Source Files on build 20631
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #20631
  • 8919b003 on github
  • Prev Build on master (#20624)
  • Next Build on master (#20637)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc