PHPackages                             benholmen/defrag - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. benholmen/defrag

ActiveLibrary[Testing &amp; Quality](/categories/testing)

benholmen/defrag
================

MS-DOS defrag output for your PHPUnit test suite

0.1.6(2y ago)931.5k[1 PRs](https://github.com/benholmen/defrag/pulls)MITPHPPHP ^8.1

Since Oct 15Pushed 1y ago2 watchersCompare

[ Source](https://github.com/benholmen/defrag)[ Packagist](https://packagist.org/packages/benholmen/defrag)[ Docs](https://github.com/benholmen/defrag)[ GitHub Sponsors](https://github.com/benholmen)[ RSS](/packages/benholmen-defrag/feed)WikiDiscussions main Synced today

READMEChangelog (7)Dependencies (5)Versions (9)Used By (0)

Defragment your PHPUnit tests
=============================

[](#defragment-your-phpunit-tests)

This package generates a satisfying Defrag-style output when running your [PHPUnit test suite](https://phpunit.de).

[![Sample output](output.gif)](output.gif)

Inspired by
-----------

[](#inspired-by)

MS-DOS 6.x included a [defrag utility](https://en.wikipedia.org/wiki/List_of_DOS_commands#DEFRAG) that honestly was just so satisfying to watch. The 90s were a different time, folks. Disk defragmentation took about an hour and physically rearranged the data on your hard drive so it was more efficient to read off the disk.

#### Defrag Running in MS-DOS 6.22

[](#defrag-running-in-ms-dos-622)

[![Defrag Running in MS-DOS 6.22](https://camo.githubusercontent.com/a5b4da4d34ffcf8c5fc528843f212fa9a0aa97560c60e4f9a368f6adb62cd82b/68747470733a2f2f696d672e796f75747562652e636f6d2f76692f4e6964777a33427a46434d2f302e6a7067)](https://www.youtube.com/watch?v=Nidwz3BzFCM "Defrag Running in MS-DOS 6.22")

Installation
------------

[](#installation)

Install the package via composer:

```
composer require benholmen/defrag --dev
```

Add the following lines to your `phpunit.xml` file:

```

```

Usage
-----

[](#usage)

Run PHPUnit as usual:

```
vendor/bin/phpunit
```

Testing
-------

[](#testing)

Of course, this produces the defrag output you'd expect.

```
composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](https://github.com/spatie/.github/blob/main/CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- [Ben Holmen](https://github.com/benholmen)
- [Jess Archer](https://github.com/jessarcher) key intel, assistance, and the fantastic [laravel/prompts](https://github.com/laravel/prompts) package

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance26

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 89.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~21 days

Recently: every ~32 days

Total

7

Last Release

863d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1056188?v=4)[Ben Holmen](/maintainers/benholmen)[@benholmen](https://github.com/benholmen)

---

Top Contributors

[![benholmen](https://avatars.githubusercontent.com/u/1056188?v=4)](https://github.com/benholmen "benholmen (41 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (2 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (2 commits)")[![itsmarsu](https://avatars.githubusercontent.com/u/19348991?v=4)](https://github.com/itsmarsu "itsmarsu (1 commits)")

---

Tags

defragphpunittestingtestingphpunitdefrag

###  Code Quality

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/benholmen-defrag/health.svg)

```
[![Health](https://phpackages.com/badges/benholmen-defrag/health.svg)](https://phpackages.com/packages/benholmen-defrag)
```

###  Alternatives

[brianium/paratest

Parallel testing for PHP

2.5k136.1M985](/packages/brianium-paratest)[spatie/phpunit-snapshot-assertions

Snapshot testing with PHPUnit

69619.8M640](/packages/spatie-phpunit-snapshot-assertions)[illuminate/console

The Illuminate Console package.

13046.0M6.5k](/packages/illuminate-console)[timacdonald/log-fake

A drop in fake logger for testing with the Laravel framework.

4236.6M68](/packages/timacdonald-log-fake)[allure-framework/allure-phpunit

Allure PHPUnit integration

6913.4M46](/packages/allure-framework-allure-phpunit)[facile-it/paraunit

paraunit

145845.1k17](/packages/facile-it-paraunit)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
