[wp-hackers] plugins unit testing
Paolo Tresso
paolo.tresso at swergroup.com
Fri Mar 8 03:50:49 UTC 2013
Hi everyone,
I'm trying to learn unit testing and use it properly in our plugins (about
time..). First thing I've learned so far is that I need to write better
code in order to test it :)
I've managed to setup tests and environment thanks to the *amazing* wp-cli
but I can't figure out how to test several things.
Example: one of our plugins deals with uploads filenames; while I can test
some step and method on debug strings, can I simulate a real file upload
process and test if my plugins plays nice with every hook? Can I create a
debug post and test save_post hooks, or this is out of the testing scope?
Thank you!
Paolo Tresso
Lead Developer
SWERgroup
http://swergroup.com
http://profiles.wordpress.org/swergroup
More information about the wp-hackers
mailing list