MockPress provides Mock-Objects and Functions to be used with a PHP unit testing framework. It simulates WordPress so that it can be used to create Unittests for plugins and other types of own components. Written by John Bintz.

MockPress on Github | A PEAR module build is available as well, please see the READMEVia: wordpress support forums.

This entry was posted in Pressed, Tools, WordPress Support and tagged , , , , , , . Bookmark the permalink.

4 Responses to MockPress

  1. The link to the MockPress Documentation is broken.

    Otherwise, I think this is exactly what I was looking for. Thanks!

  2. wpstorecart says:

    Do you have any experience setting this up? I have PHPUnit installed properly, and I am trying to get it generate skeleton test files, but it keeps failing because of WordPress functions that are not defined, as if it’s not seeing Mockpress, even though it’s loaded via require_once(); Any help or thoughts?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.