Wordpress/tests
Timothy Jacobs d803f6bf82 REST API: Refactor WP_REST_Server::dispatch() to make internal logic reusable.
#50244 aims to introduce batch processing in the REST API. An important feature is the ability to enforce that all requests have valid data before executing the route callbacks in "pre-validate" mode.

This necessitates splitting `WP_REST_Server::dispatch()` into two methods so the batch controller can determine the request handler to perform pre-validation and then respond to the requests.

The two new methods, `match_request_to_handler` and `respond_to_request`, have a public visibility, but are marked as `@access private`. This is to allow for iteration on the batch controller to happen in the Gutenberg repository. Developers should not rely upon these methods, their visibility may change in the future.

See #50244.
Props andraganescu, zieladam, TimothyBlynJacobs.


git-svn-id: https://develop.svn.wordpress.org/trunk@48947 602fd350-edb4-49c9-b593-d223f7449a82
2020-09-05 21:50:31 +00:00
..
e2e Editor: update JavaScript packages 2020-06-26 13:31:11 +00:00
gutenberg Block Editor: Add a script to run Gutenberg end 2 end tests on Core. 2020-07-07 16:06:43 +00:00
phpunit REST API: Refactor WP_REST_Server::dispatch() to make internal logic reusable. 2020-09-05 21:50:31 +00:00
qunit Tests: Update wp-api-generated.js to reflect the new "Reusable Blocks" post type label. 2020-08-23 14:38:40 +00:00