PHPackages                             phlib/mockfunction - 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. phlib/mockfunction

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

phlib/mockfunction
==================

Library to aid the testing of global functions, by creating an instance of the function in the namespace

1.0.0(11y ago)057PHPPHP ~5.4CI failing

Since Feb 22Pushed 6y ago1 watchersCompare

[ Source](https://github.com/phlib/mockfunction)[ Packagist](https://packagist.org/packages/phlib/mockfunction)[ RSS](/packages/phlib-mockfunction/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (2)Used By (0)

phlib/mockfunction
==================

[](#phlibmockfunction)

[![Build Status](https://camo.githubusercontent.com/de0ae96b72b1cd7aaa416ce3361245e28ca0bd773ab2ff600a08009449f9713e/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f70686c69622f6d6f636b66756e6374696f6e2f6d61737465722e737667)](https://travis-ci.org/phlib/mockfunction)[![Codecov](https://camo.githubusercontent.com/88168874e73f8644937c43bf988b963df49e738b922c239fe262a0ee4572d708/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f70686c69622f6d6f636b66756e6374696f6e2e737667)](https://codecov.io/gh/phlib/mockfunction)[![Latest Stable Version](https://camo.githubusercontent.com/1b8e43dfab9367f006acdd4118db6f97d832b072bd2fd5ec5febdda8e734e4e3/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f70686c69622f6d6f636b66756e6374696f6e2e737667)](https://packagist.org/packages/phlib/mockfunction)[![Total Downloads](https://camo.githubusercontent.com/bc1a2144d473516b3e6f3b7ed58b86f7d2727411074a8b64404437f7707c99a9/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f70686c69622f6d6f636b66756e6374696f6e2e737667)](https://packagist.org/packages/phlib/mockfunction)[![Licence](https://camo.githubusercontent.com/6378940f357293368c6a3d248aee4ae92976453f6219b58980ca5b671b0e544f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f70686c69622f6d6f636b66756e6374696f6e2e737667)](https://camo.githubusercontent.com/6378940f357293368c6a3d248aee4ae92976453f6219b58980ca5b671b0e544f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f70686c69622f6d6f636b66756e6374696f6e2e737667)

Abandoned
---------

[](#abandoned)

This package is abandoned and no longer supported. We recommend trying [php-mock/php-mock-phpunit](https://github.com/php-mock/php-mock-phpunit).

License
-------

[](#license)

This package is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this program. If not, see .

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 73.3% 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

Unknown

Total

1

Last Release

4148d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/135b7ddf9ec91c412e1b18174f81d1ad2bef66e732624195c156717c96b13731?d=identicon)[letssurf](/maintainers/letssurf)

![](https://www.gravatar.com/avatar/10c53cdcfb3a6d299820aecb993521cc1a972baa09fd8f31d2468908cded7e1d?d=identicon)[chrisminett](/maintainers/chrisminett)

---

Top Contributors

[![jdempster](https://avatars.githubusercontent.com/u/10297?v=4)](https://github.com/jdempster "jdempster (11 commits)")[![chrisminett](https://avatars.githubusercontent.com/u/1084019?v=4)](https://github.com/chrisminett "chrisminett (4 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/phlib-mockfunction/health.svg)

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

###  Alternatives

[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k42.5M40.8k](/packages/orchestra-testbench)[jasonmccreary/laravel-test-assertions

A set of helpful assertions when testing Laravel applications.

3514.2M39](/packages/jasonmccreary-laravel-test-assertions)[codeception/mockery-module

Mockery Module for Codeception

344.4M86](/packages/codeception-mockery-module)[markhuot/craft-pest-core

A Pest runner

2119.9k10](/packages/markhuot-craft-pest-core)[lastzero/test-tools

Increases testing productivity by adding a service container and self-initializing fakes to PHPUnit

2244.5k13](/packages/lastzero-test-tools)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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