I'm trying to set up a Test Driven Development environment and I was wondering if it's possible to run the WordPress test suite without a web server. I'm on a mac (10.7.5) and I've set up phpunit and the mysql server.

  • 1
    What do you mean by WordPress test suite? WP requires a web server to run, like any website, but you can set up Apache on your localhost. – vancoder Apr 26 '13 at 20:25
  • 1
    You might look at getting MAMP setup. From the looks of it, this may help you – NW Tech Apr 26 '13 at 20:56
  • 1
    @vancoder - I'm talking about the unit tests that are available for phpunit. see: make.wordpress.org/core/handbook/automated-testing for more info. – user341493 Apr 26 '13 at 22:00

You're on a Mac! You have two of the three components you need for a Web server by default. Apache and PHP. All you need to do now is get MySQL. There are plenty of tutorials on how to do this and can be found with Google.

Of course NW Tech recommendation of MAMP is another great option. Especially if you haven't managed a server before. Check out the WordPress Codex.

  • Looks like he got it working, but he has a new post with issues, see here – NW Tech Apr 26 '13 at 23:39
  • @Jallits I'm trying to develop in a Test Driven manner so I want to run all of my test from my laptop. I can run tests using phpunit without having a webserver running and I was trying to get the wordpress unit tests running without one either. – user341493 Apr 26 '13 at 23:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.