PHPackages                             automattic/phpunit-select-config - 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. automattic/phpunit-select-config

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

automattic/phpunit-select-config
================================

Run PHPUnit, choosing a configuration file by version.

v1.0.3(1y ago)14.7k↓32.6%120GPL-2.0-or-laterPHPPHP &gt;=5.4CI passing

Since Mar 12Pushed 1mo ago2 watchersCompare

[ Source](https://github.com/Automattic/phpunit-select-config)[ Packagist](https://packagist.org/packages/automattic/phpunit-select-config)[ RSS](/packages/automattic-phpunit-select-config/feed)WikiDiscussions trunk Synced 1mo ago

READMEChangelogDependencies (5)Versions (6)Used By (20)

phpunit-select-config
=====================

[](#phpunit-select-config)

This is a shim to run PHPUnit while selecting a configuration file based on the PHPUnit major version number.

This is intended for use in projects that have to test with a wide variety of PHP versions, which typically also means a wide variety of PHPUnit versions which may have incompatible configuration file formats.

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

[](#installation)

Require using `composer require --dev automattic/phpunit-select-config`.

This will install the `phpunit-select-config` tool into `vendor/bin/`, which you might add to your PATH, or you might run it via `composer exec -- phpunit-select-config`.

Usage
-----

[](#usage)

Create PHPUnit configuration files for each relevant PHPUnit version following a common naming pattern. For example, you might name the config for PHPUnit 8 `phpunit.8.xml.dist`, the one for PHPUnit 9 `phpunit.9.xml.dist`, the one for PHPUnit 10 `phpunit.10.xml.dist`, and so on.

Then, instead of running `phpunit` directly, run `phpunit-select-config phpunit.#.xml.dist`. Any additional arguments to PHPUnit may follow. The `#` character in the filename-pattern will be replaced with the PHPUnit major version and passed as the `--configuration` argument to PHPUnit.

###  Health Score

41

—

FairBetter than 89% of packages

Maintenance71

Regular maintenance activity

Popularity25

Limited adoption so far

Community31

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 52.4% 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 ~15 days

Total

4

Last Release

385d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7c5869ecbb8e0eac7e8b8e0f3cf7bdd8d5fcdc4abc10a72281872c53f8639d44?d=identicon)[automattic](/maintainers/automattic)

---

Top Contributors

[![anomiex](https://avatars.githubusercontent.com/u/1030580?v=4)](https://github.com/anomiex "anomiex (22 commits)")[![tbradsha](https://avatars.githubusercontent.com/u/32492176?v=4)](https://github.com/tbradsha "tbradsha (14 commits)")[![manzoorwanijk](https://avatars.githubusercontent.com/u/18226415?v=4)](https://github.com/manzoorwanijk "manzoorwanijk (2 commits)")[![gmjuhasz](https://avatars.githubusercontent.com/u/36671565?v=4)](https://github.com/gmjuhasz "gmjuhasz (1 commits)")[![chihsuan](https://avatars.githubusercontent.com/u/4344253?v=4)](https://github.com/chihsuan "chihsuan (1 commits)")[![CGastrell](https://avatars.githubusercontent.com/u/157240?v=4)](https://github.com/CGastrell "CGastrell (1 commits)")[![adamwoodnz](https://avatars.githubusercontent.com/u/1017872?v=4)](https://github.com/adamwoodnz "adamwoodnz (1 commits)")

---

Tags

phpunitdevconfig

### Embed Badge

![Health badge](/badges/automattic-phpunit-select-config/health.svg)

```
[![Health](https://phpackages.com/badges/automattic-phpunit-select-config/health.svg)](https://phpackages.com/packages/automattic-phpunit-select-config)
```

###  Alternatives

[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k39.1M32.1k](/packages/orchestra-testbench)[brianium/paratest

Parallel testing for PHP

2.5k118.8M754](/packages/brianium-paratest)[spatie/phpunit-snapshot-assertions

Snapshot testing with PHPUnit

69617.9M510](/packages/spatie-phpunit-snapshot-assertions)[matthiasnoback/symfony-dependency-injection-test

Library for testing user classes related to the Symfony Dependency Injection Component

2439.0M887](/packages/matthiasnoback-symfony-dependency-injection-test)[orchestra/testbench-core

Testing Helper for Laravel Development

27043.7M310](/packages/orchestra-testbench-core)[matthiasnoback/symfony-config-test

Library for testing user classes related to the Symfony Config Component

1679.8M395](/packages/matthiasnoback-symfony-config-test)

PHPackages © 2026

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