Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use? #25

Open
Luc45 opened this issue Sep 23, 2018 · 1 comment
Open

How to use? #25

Luc45 opened this issue Sep 23, 2018 · 1 comment
Labels

Comments

@Luc45
Copy link

Luc45 commented Sep 23, 2018

Hi!

First of all, thanks for the effort on this open-source project! :)

I'm having some trouble getting it to work though - I'm trying to use this as a skeleton for a new plugin.

However, when running wpppb-init, it asks for WordPress core tests directory. I don't intend to contribute to WP Core. Did I understand something wrong about the purpose of this project?

Thanks!!

@JDGrimes
Copy link
Owner

Hey @Luc45. I've been meaning to write some better docs, sorry I haven't made things clearer. The project is for testing plugins, however, it builds on top of the testing tools that WP core uses. Basically, WP core has built some custom WP-specific stuff that is useful for testing any WP-related code, whether core, plugin, theme, etc. So instead of reinventing the wheel, WPPPB just builds on top of some of the things that the WP core team has already built. That is why it asks for the core tests directory.

Here is an older tutorial that I wrote on plugin unit testing, which includes the WP tests set up step (although the later steps are now replaced by WPPPB). However, in more recent years, I have switched to using VVV to set this up, since it includes the WP develop repo (which has the core tests directory in it). Even if you aren't planing to contribute to core (which is probably bound to happen anyway, since you'll likely find some bugs as you build anything complex on top of WP), I'd recommend getting VVV set up if you haven't already. It is very useful in plugin development. Then, once you have VVV, you can point WPPPB to the tests directory included with it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants