What’s the proper method of installing a plugin during unit testing?

Then there’s the Composer approach described here by Steve Grunwell, to load WooCommerce as a development dependency: $ composer require –dev –prefer-source woocommerce/woocommerce where he mentioned doing some composer.json adjustments, like moving WooCommerce under the vendor path: “extra”: { “installer-paths”: { “vendor/{$vendor}/{$name}”: [ “woocommerce/woocommerce” ] } } and include WooCommerce tests in the generated autoloader: … Read more

Developing, Testing and Releasing

There is a bit of personal philosophy that goes into a deployment workflow. It’s not an easy question to answer outright without knowing your experience with servers and version control, your operating system, hosting, client’s experience and tech culture, etc… Here’s a similar question that has a lot of explanation. For content deployment, you can … Read more

Testing hooks callback

Test in isolation When developing a plugin, the best way to test it is without loading the WordPress environment. If you write code that can be easily tested without WordPress, your code becomes better. Every component that is unit tested, should be tested in isolation: when you test a class, you only have to test … Read more

How to configure “Shorten command line” method for whole project in IntelliJ

You can set up a default way to shorten the command line and use it as a template for further configurations by changing the default JUnit Run/Debug Configuration template. Then all new Run/Debug configuration you create in project will use the same option. Here is the related blog post about configurable command line shortener option.