PHPackages                             wp-graphql/wp-graphql-testcase - 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. wp-graphql/wp-graphql-testcase

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

wp-graphql/wp-graphql-testcase
==============================

Codeception module for WPGraphQL API testing

v3.4.0(1y ago)9245.6k↑28%610MITPHP

Since Aug 26Pushed 1y ago3 watchersCompare

[ Source](https://github.com/wp-graphql/wp-graphql-testcase)[ Packagist](https://packagist.org/packages/wp-graphql/wp-graphql-testcase)[ RSS](/packages/wp-graphql-wp-graphql-testcase/feed)WikiDiscussions develop Synced 1mo ago

READMEChangelog (10)Dependencies (8)Versions (33)Used By (10)

WPGraphQL TestCase
==================

[](#wpgraphql-testcase)

[![continuous_integration](https://github.com/wp-graphql/wp-graphql-testcase/workflows/continuous_integration/badge.svg)](https://github.com/wp-graphql/wp-graphql-testcase/workflows/continuous_integration/badge.svg)[![Coverage Status](https://camo.githubusercontent.com/d006a697087bdfa389595f5909a0dd895665f990dde2a4e9262300f218b0b019/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f77702d6772617068716c2f77702d6772617068716c2d74657374636173652f62616467652e737667)](https://coveralls.io/github/wp-graphql/wp-graphql-testcase)

Is a library of tools for testing WPGraphQL APIs, designed for both WPGraphQL and WPGraphQL extension development. Currently the library only consisted of a Codeception Testcase built on top wp-browser's WPTestCase class.

Installing
----------

[](#installing)

1. Run `composer require wp-graphql/wp-graphql-testcase` from your project directory in the terminal.

Codeception Only
----------------

[](#codeception-only)

1. If your didn't already have codeception installed in the project, run `vendor/bin/codecept init wpbrowser`.
2. To make a test case generate a with `vendor/bin/codecept generate:wpunit wpunit TestName`. Then just change the extending class to `\Tests\WPGraphQL\TestCase\WPGraphQLTestCase`🤷‍♂️

Going Forward
-------------

[](#going-forward)

There are plans to add more to this library, and contribution are greatly appreciated 🙏.

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

[](#contributing)

To contribute, fork this repository and open a PR with your requested changes back into the main repository.

### Local Development

[](#local-development)

To develop locally, you need to have Docker and Composer installed.

#### Composer Setup

[](#composer-setup)

To ensure you have the necessary local dependencies, first run `composer install`.

#### Docker Setup

[](#docker-setup)

This project currently uses a `docker-compose.yml` v2 file. To spin this up, run `docker-compose up -d`.

#### Local Tests

[](#local-tests)

To run the local tests, use `composer run-phpunit` or `composer run-codeception`. You should see the tests pass with output generated in the terminal.

#### Test Coverage

[](#test-coverage)

The CI process uses [coveralls.io](https://coveralls.io/) to store coverage reports. This is available for free for open-source projects, and is required to run the CI process. Sign up for free and add your `COVERALLS_REPO_TOKEN` value to GitHub Actions secrets.

Contributors
------------

[](#contributors)

[![](https://github.com/kidunot89.png?size=80 "kidunot89")](https://github.com/kidunot89)[![](https://github.com/missionmike.png?size=80 "missionmike")](https://github.com/missionmike)

###  Health Score

45

—

FairBetter than 93% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity43

Moderate usage in the ecosystem

Community26

Small or concentrated contributor base

Maturity66

Established project with proven stability

 Bus Factor1

Top contributor holds 63.6% 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 ~68 days

Recently: every ~21 days

Total

22

Last Release

648d ago

Major Versions

v1.1.3 → v2.0.02021-06-12

v2.4.1 → v3.0.02024-05-02

PHP version history (3 changes)v1.1.0PHP &gt;=7.1

v2.1.1PHP ^7.1 || ^8.0

v2.4.0PHP ^8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1260765?v=4)[Jason Bahl](/maintainers/jasonbahl)[@jasonbahl](https://github.com/jasonbahl)

![](https://www.gravatar.com/avatar/5965dfcc6b765dbf5044c2fca1879460a80087418a9f55536b85ec2bdf511244?d=identicon)[kidunot89](/maintainers/kidunot89)

---

Top Contributors

[![kidunot89](https://avatars.githubusercontent.com/u/13604318?v=4)](https://github.com/kidunot89 "kidunot89 (124 commits)")[![jasonbahl](https://avatars.githubusercontent.com/u/1260765?v=4)](https://github.com/jasonbahl "jasonbahl (38 commits)")[![missionmike](https://avatars.githubusercontent.com/u/4269287?v=4)](https://github.com/missionmike "missionmike (29 commits)")[![justlevine](https://avatars.githubusercontent.com/u/29322304?v=4)](https://github.com/justlevine "justlevine (3 commits)")[![markkelnar](https://avatars.githubusercontent.com/u/749603?v=4)](https://github.com/markkelnar "markkelnar (1 commits)")

---

Tags

codeceptionphpunitwordpresswpbrowserwpgraphql

###  Code Quality

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/wp-graphql-wp-graphql-testcase/health.svg)

```
[![Health](https://phpackages.com/badges/wp-graphql-wp-graphql-testcase/health.svg)](https://phpackages.com/packages/wp-graphql-wp-graphql-testcase)
```

###  Alternatives

[phpspec/prophecy

Highly opinionated mocking framework for PHP 5.3+

8.5k551.7M682](/packages/phpspec-prophecy)[brianium/paratest

Parallel testing for PHP

2.5k118.8M754](/packages/brianium-paratest)[beberlei/assert

Thin assertion library for input validation in business models.

2.4k96.9M570](/packages/beberlei-assert)[mikey179/vfsstream

Virtual file system to mock the real file system in unit tests.

1.4k108.0M2.7k](/packages/mikey179-vfsstream)[orchestra/testbench

Laravel Testing Helper for Packages Development

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

Specification-oriented BDD framework for PHP 7.1+

1.9k36.7M3.1k](/packages/phpspec-phpspec)

PHPackages © 2026

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