Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully
Server metrics [RAM: ▲0.02MB] [CPU: ▼160.28ms] Passed 4 tests
A check of server-side resources used by WordPress Instant Articles
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.86 ▲0.02 | 23.22 ▼0.08 |
Dashboard /wp-admin | 3.09 ▲0.02 | 36.04 ▲1.86 |
Posts /wp-admin/edit.php | 3.14 ▲0.03 | 33.25 ▲3.96 |
Add New Post /wp-admin/post-new.php | 5.45 ▲0.01 | 67.55 ▼638.26 |
Media Library /wp-admin/upload.php | 3.03 ▲0.03 | 23.82 ▼4.62 |
Server storage [IO: ▲4.57MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 332 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
WordPress Instant Articles: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,714 ▲103 | 15.96 ▲0.72 | 6.26 ▼2.32 | 76.39 ▼4.53 |
Dashboard /wp-admin | 2,976 ▲80 | 6.07 ▼0.07 | 118.45 ▼13.81 | 188.49 ▲13.79 |
Posts /wp-admin/edit.php | 2,788 ▲51 | 2.93 ▼0.31 | 62.00 ▼1.77 | 135.00 ▼7.49 |
Add New Post /wp-admin/post-new.php | 3,972 ▲165 | 21.24 ▲2.06 | 436.21 ▼19.31 | 198.87 ▲18.06 |
Media Library /wp-admin/upload.php | 1,802 ▲50 | 5.74 ▲0.18 | 124.49 ▼19.58 | 205.66 ▲25.13 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
- 5× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/instant-articles/partials/admin-global-css.php
- > /wp-content/plugins/instant-articles/partials/admin-help-tab-overview.php
- > /wp-content/plugins/instant-articles/partials/admin-help-tab-prerender.php
- > /wp-content/plugins/instant-articles/partials/admin-help-tab-dnsprefetch.php
- > /wp-content/plugins/instant-articles/partials/admin-css.php
- 14× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function do_action() in wp-content/plugins/instant-articles/libraries/cmb2/bootstrap.php:17
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/instant-articles/libraries/cmb2/tests/cmb-tests-base.php:10
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/instant-articles/libraries/cmb2/tests/cmb-tests-base.php:10
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/instant-articles/libraries/cmb2/tests/cmb-tests-base.php:10
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/instant-articles/libraries/cmb2/tests/cmb-tests-base.php:10
- > PHP Fatal error
require_once(): Failed opening required '/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/instant-articles/libraries/cmb2/tests/bootstrap.php on line 24
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-articles/libraries/cmb2/example-functions.php:68
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/instant-articles/libraries/cmb2/tests/cmb-tests-base.php:10
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-articles/libraries/cmb2/init.php:119
- > PHP Warning
require_once(/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/instant-articles/libraries/cmb2/tests/bootstrap.php on line 24
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
- Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
instant-articles/instant-articles.php Passed 13 tests
The primary PHP file in "WordPress Instant Articles" version 1.4 is used by WordPress to initiate all plugin functionality
71 characters long description:
Increase your site performance with DNS prefetching and HTML5 prerender
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected88,244 lines of code in 185 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
XML | 2 | 0 | 0 | 47,741 |
PO File | 119 | 12,614 | 16,209 | 28,917 |
PHP | 34 | 1,421 | 2,422 | 4,944 |
CSS | 4 | 1,008 | 1,022 | 3,888 |
Sass | 11 | 168 | 23 | 1,116 |
JavaScript | 4 | 186 | 174 | 825 |
Markdown | 4 | 164 | 0 | 458 |
YAML | 2 | 9 | 0 | 152 |
JSON | 3 | 0 | 0 | 121 |
Bourne Shell | 1 | 19 | 7 | 71 |
SVG | 1 | 0 | 1 | 11 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 20.57 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 113.00 |
Average method complexity | 2.68 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 16.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 30 | |
▷ Abstract classes | 1 | 3.33% |
▷ Concrete classes | 29 | 96.67% |
▷ Final classes | 0 | 0.00% |
Methods | 350 | |
▷ Static methods | 29 | 8.29% |
▷ Public methods | 336 | 96.00% |
▷ Protected methods | 9 | 2.57% |
▷ Private methods | 5 | 1.43% |
Functions | 27 | |
▷ Named functions | 27 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 6 | |
▷ Global constants | 3 | 50.00% |
▷ Class constants | 3 | 50.00% |
▷ Public constants | 3 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
14 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
libraries/cmb2/images/ui-bg_glass_95_fef1ec_1x400.png | 0.12KB | 0.14KB | 0.00% |
libraries/cmb2/images/ui-bg_flat_75_ffffff_40x100.png | 0.17KB | 0.08KB | ▼ 51.12% |
libraries/cmb2/images/ui-bg_glass_55_fbf9ee_1x400.png | 0.12KB | 0.14KB | 0.00% |
libraries/cmb2/images/ui-icons_454545_256x240.png | 4.27KB | 4.11KB | ▼ 3.78% |
libraries/cmb2/images/ui-bg_highlight-soft_75_cccccc_1x100.png | 0.10KB | 0.17KB | 0.00% |