PHPackages                             paulthebaud/phpunit-generator - 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. paulthebaud/phpunit-generator

Abandoned → [phpunitgen/console](/?search=phpunitgen%2Fconsole)ArchivedLibrary[Testing &amp; Quality](/categories/testing)

paulthebaud/phpunit-generator
=============================

A PHPUnit 6 / 7 tests skeletons generator

2.1.5(7y ago)366.9k32MITPHPPHP ~7.1

Since Aug 2Pushed 6y ago5 watchersCompare

[ Source](https://github.com/paul-thebaud/phpunit-generator)[ Packagist](https://packagist.org/packages/paulthebaud/phpunit-generator)[ Docs](https://github.com/paul-thebaud/phpunit-generator)[ RSS](/packages/paulthebaud-phpunit-generator/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (8)Dependencies (14)Versions (20)Used By (2)

[![](https://camo.githubusercontent.com/07d49eec162101d87a66803fbf53b350796250003b2769cdf9fd891f7b2b547b/68747470733a2f2f7261772e6769746875622e636f6d2f7061756c2d746865626175642f706870756e69742d67656e657261746f722d6173736574732f6d61737465722f6c6f676f732f6c6f676f2e7376673f73616e6974697a653d74727565)](https://camo.githubusercontent.com/07d49eec162101d87a66803fbf53b350796250003b2769cdf9fd891f7b2b547b/68747470733a2f2f7261772e6769746875622e636f6d2f7061756c2d746865626175642f706870756e69742d67656e657261746f722d6173736574732f6d61737465722f6c6f676f732f6c6f676f2e7376673f73616e6974697a653d74727565)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d36d4334961c7a252c3a3f87c7997e5d96b3198c6adf9c794e39bf649cc45b01/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7061756c746865626175642f706870756e69742d67656e657261746f722e737667)](https://packagist.org/packages/paulthebaud/phpunit-generator)[![Minimum PHP Version](https://camo.githubusercontent.com/824c5c4ccb56537db3b3b53bb43d7b8edc6286f3b3d1705525e0821dfd22d27e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253345253344253230372e312d3838393242462e737667)](https://php.net/)[![Build Status](https://camo.githubusercontent.com/4e1c422a27bcf777422f5186a04787692523146bf1e7024b746e4710213c4764/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7061756c2d746865626175642f706870756e69742d67656e657261746f722f6d61737465722e737667)](https://travis-ci.org/paul-thebaud/phpunit-generator)[![Coverage Status](https://camo.githubusercontent.com/4fb4852da0cbaf79d43bf1b84e57ae6b263f5de50b2d57f7e8f5bade1da71e7f/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f7061756c2d746865626175642f706870756e69742d67656e657261746f722f6d61737465722e737667)](https://coveralls.io/github/paul-thebaud/phpunit-generator)[![Scrutinizer](https://camo.githubusercontent.com/1bea08ba9df9f364dbf4d47a745c68bf252a23904699b8ae2a19fcfc2c29efa6/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f7061756c2d746865626175642f706870756e69742d67656e657261746f722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/paul-thebaud/phpunit-generator/)[![Software License](https://camo.githubusercontent.com/074b89bca64d3edc93a1db6c7e3b1636b874540ba91d66367c0e5e354c56d0ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e737667)](LICENSE.md)[![Total Downloads](https://camo.githubusercontent.com/0ce55890a13a42661c3c030e82d4905cf2a9db5da3d73744892050f1a29d1742/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7061756c746865626175642f706870756e69742d67656e657261746f722e737667)](https://packagist.org/packages/paulthebaud/phpunit-generator)

⚠️ Repository and package abandonned ⚠️
---------------------------------------

[](#warning-repository-and-package-abandonned-warning)

**This repository and the `paulthebaud/phpunit-generator` package are abandonned, in favor of the new version you can check out [here](https://phpunitgen.io). If you want to use as command line, use this package instead: [phpunitgen/console](https://github.com/paul-thebaud/phpunitgen-console).**

---

**Following remains for historical purpose.**

PhpUnitGen is an open source development tool which will help you writing your unit tests for PHPUnit 6 / 7:

- Generate unit skeleton for all PHP files including classes, traits, interfaces and global functions.
- Automatically generate a few simple unit tests (like getter / setter methods tests, class instantiation).

You can try and use this package on a web application, at [phpunitgen.io](https://phpunitgen.io).

**Version 2 of PhpUnitGen is now available, but be careful, it breaks the PhpUnitGen 1.x.x API.**

[![Image of PhpUnitGen rendering](https://camo.githubusercontent.com/5b1023e3c5fe3d9caa592e5fa7c95ceaa7a17b45a51e74723baebbe6997fb4c6/68747470733a2f2f7261772e6769746875622e636f6d2f7061756c2d746865626175642f706870756e69742d67656e657261746f722d6173736574732f6d61737465722f6c6f676f732f6578616d706c652e706e67)](https://camo.githubusercontent.com/5b1023e3c5fe3d9caa592e5fa7c95ceaa7a17b45a51e74723baebbe6997fb4c6/68747470733a2f2f7261772e6769746875622e636f6d2f7061756c2d746865626175642f706870756e69742d67656e657261746f722d6173736574732f6d61737465722f6c6f676f732f6578616d706c652e706e67)

Package structure
-----------------

[](#package-structure)

```
build/      ==> Build results (code coverage ...) [only after running composer test].
config/     ==> Default PhpUnitGen configurations.
examples/   ==> Examples about this package (configuration, parsing examples).
src/        ==> Package source files.
template/   ==> Package template for generated tests skeletons.
tests/      ==> Package unit tests.
vendor/     ==> Composer dependencies [only after running composer install].

```

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

[](#installation)

Best way to install this package is with composer dependency manager.

```
$ composer require --dev paulthebaud/phpunit-generator ^2.0
```

`--dev` option is used to install this package only in development environment.

Documentation
-------------

[](#documentation)

PhpUnitGen documentation is available online on [doc.phpunitgen.io](https://doc.phpunitgen.io).

It give multiple information on PhpUnitGen:

- [Installation of the package](https://doc.phpunitgen.io/en/installation.html).
- [Usage of web application](https://doc.phpunitgen.io/en/website.html).
- [Usage of command line](https://doc.phpunitgen.io/en/terminal.html).
- [Usage of with PHP code](https://doc.phpunitgen.io/en/php.html).
- [Usage of annotations](https://doc.phpunitgen.io/en/annotations.html).
- [Communication around the PhpUnitGen project](https://doc.phpunitgen.io/en/about.html).

Running tests
-------------

[](#running-tests)

```
$ composer test
```

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for more details.

Credits
-------

[](#credits)

- [Paul Thébaud](https://github.com/paul-thebaud)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

36

—

LowBetter than 82% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity29

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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 ~34 days

Recently: every ~81 days

Total

18

Last Release

2630d ago

Major Versions

1.1.5 → 2.0.02018-03-01

PHP version history (2 changes)1.0.0PHP ^7.0

2.0.0PHP ~7.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/37683411df2af2242c422edbbbc786dd5bfd166b96ce2d174f5b3bf780bce5b4?d=identicon)[paul-thebaud](/maintainers/paul-thebaud)

---

Top Contributors

[![paul-thebaud](https://avatars.githubusercontent.com/u/18483833?v=4)](https://github.com/paul-thebaud "paul-thebaud (184 commits)")

---

Tags

generatorphpphp7phpunitunit-testphpphpunitunittestgeneratortestsPHP7

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/paulthebaud-phpunit-generator/health.svg)

```
[![Health](https://phpackages.com/badges/paulthebaud-phpunit-generator/health.svg)](https://phpackages.com/packages/paulthebaud-phpunit-generator)
```

###  Alternatives

[behat/behat

Scenario-oriented BDD framework for PHP

4.0k96.8M2.0k](/packages/behat-behat)[vimeo/psalm

A static analysis tool for finding errors in PHP applications

5.8k77.5M6.7k](/packages/vimeo-psalm)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[contao/core-bundle

Contao Open Source CMS

1231.6M2.4k](/packages/contao-core-bundle)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[colinodell/psr-testlogger

PSR-3 compliant test logger based on psr/log v1's, but compatible with v2 and v3 too!

1712.1M47](/packages/colinodell-psr-testlogger)

PHPackages © 2026

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