-
Notifications
You must be signed in to change notification settings - Fork 382
Discovery around adding performance profiling/testing #1017
Copy link
Copy link
Closed
Labels
EnhancementNew feature or improvement of an existing oneNew feature or improvement of an existing one
Description
In light of #993 it is clear we need more performance profiling in place for the plugin.
- Using the scripts used to populate a site with test content, generate a post fully populated with embeds, widgets, and comments, with enough lorem ipsum text to count as a long-form post. Then with the “AMP Conf” theme active, capture the source of the page. Then save the output to
testsdirectory for use in testing. - Run Xdebug profiler and do a sanity check for performance bottlenecks.
- Add a PHPUnit test for performance, loading up the captured HTML output and making sure the processing of the HTML does not take more than a reasonable amount of time.
- Ensure that external HTTP requests are mocked to prevent network requests from causing periodic failures. (Aside: Make sure all other requests in tests are also mocked to prevent any external requests from hitting the network when running tests.)
- Add a new test suite that includes the performance testing and also the slow
runInSeparateProcesstests. Let this test suite be run with all the others on Travis CI, but exclude it by default on the local environment. Or rather, as in the case of Gutenberg, use environment variable for this same purpose. A separate testsuite/group seems better.
See also #990 for sending back server timings via HTTP response headers.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
EnhancementNew feature or improvement of an existing oneNew feature or improvement of an existing one