Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully
Server metrics [RAM: ▼0.71MB] [CPU: ▼178.90ms] Passed 4 tests
A check of server-side resources used by Ketchup Coupons
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.89 ▲0.17 | 23.24 ▼1.20 |
Dashboard /wp-admin | 2.94 ▼0.11 | 19.41 ▼25.45 |
Posts /wp-admin/edit.php | 2.94 ▼0.16 | 19.16 ▼27.43 |
Add New Post /wp-admin/post-new.php | 2.94 ▼2.49 | 18.56 ▼643.97 |
Media Library /wp-admin/upload.php | 2.94 ▼0.06 | 18.85 ▼18.74 |
Coupon Tags /wp-admin/edit-tags.php?taxonomy=ketchup-coupon-tag&post_type=ketchup-coupon | 2.94 | 18.41 |
All Coupons /wp-admin/edit.php?post_type=ketchup-coupon | 2.94 | 19.26 |
Add New /wp-admin/post-new.php?post_type=ketchup-coupon | 2.94 | 18.19 |
Coupon Categories /wp-admin/edit-tags.php?taxonomy=ketchup-coupon-category&post_type=ketchup-coupon | 2.94 | 19.26 |
Server storage [IO: ▲0.33MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 32 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
An overview of browser requirements for Ketchup Coupons
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,945 ▲373 | 17.38 ▲1.36 | 11.38 ▼0.84 | 44.31 ▼4.49 |
Dashboard /wp-admin | 3,224 ▲293 | 7.85 ▲1.86 | 168.65 ▲15.34 | 119.43 ▲4.76 |
Posts /wp-admin/edit.php | 3,006 ▲267 | 4.15 ▲1.43 | 94.08 ▲22.04 | 89.20 ▼2.07 |
Add New Post /wp-admin/post-new.php | 1,688 ▲188 | 21.99 ▲3.16 | 292.97 ▼105.32 | 111.62 ▼0.91 |
Media Library /wp-admin/upload.php | 1,855 ▲48 | 4.80 ▼0.23 | 118.72 ▼40.90 | 121.03 ▼0.79 |
Coupon Tags /wp-admin/edit-tags.php?taxonomy=ketchup-coupon-tag&post_type=ketchup-coupon | 1,979 | 3.74 | 81.08 | 77.23 |
All Coupons /wp-admin/edit.php?post_type=ketchup-coupon | 1,697 | 4.03 | 81.14 | 71.33 |
Add New /wp-admin/post-new.php?post_type=ketchup-coupon | 2,801 | 5.39 | 129.09 | 111.51 |
Coupon Categories /wp-admin/edit-tags.php?taxonomy=ketchup-coupon-category&post_type=ketchup-coupon | 2,010 | 3.73 | 84.99 | 87.93 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
- Uninstall procedure validation failed for this plugin
- > Warning in wp-content/plugins/ketchup-coupons/includes/metaboxes/init.php+746
count(): Parameter must be an array or an object that implements Countable
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
- 5 occurences, only the last one shown
- > GET request to /wp-admin/edit-tags.php?taxonomy=ketchup-coupon-category&post_type=ketchup-coupon
- > Warning in wp-content/plugins/ketchup-coupons/includes/metaboxes/init.php+746
count(): Parameter must be an array or an object that implements Countable
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/ketchup-coupons/ketchup-coupons.php
- 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/ketchup-coupons/includes/coupon-functions.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/ketchup-coupons/includes/metaboxes/init.php:41
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
2 plugin tags: shortcodes, custom shortcodes
ketchup-coupons/ketchup-coupons.php Passed 13 tests
The main PHP file in "Ketchup Coupons" ver. 0.1 adds more information about the plugin and also serves as the entry point for this plugin
51 characters long description:
This plugin enables a very simple coupon post type.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected4,744 lines of code in 16 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 4 | 306 | 374 | 2,169 |
PHP | 8 | 522 | 1,002 | 1,785 |
CSS | 2 | 61 | 21 | 540 |
Markdown | 2 | 74 | 0 | 250 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.53 |
Average class complexity | 66.50 |
▷ Minimum class complexity | 20.00 |
▷ Maximum class complexity | 136.00 |
Average method complexity | 3.95 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 35.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 6 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 133 | |
▷ Static methods | 34 | 25.56% |
▷ Public methods | 131 | 98.50% |
▷ Protected methods | 2 | 1.50% |
▷ Private methods | 0 | 0.00% |
Functions | 12 | |
▷ Named functions | 12 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 1 | 50.00% |
▷ Class constants | 1 | 50.00% |
▷ Public constants | 1 | 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 |
includes/metaboxes/images/ui-bg_glass_65_ffffff_1x400.png | 0.10KB | 0.10KB | ▼ 5.71% |
includes/metaboxes/images/ui-bg_flat_75_ffffff_40x100.png | 0.17KB | 0.08KB | ▼ 51.12% |
includes/metaboxes/images/ui-bg_glass_75_e6e6e6_1x400.png | 0.11KB | 0.14KB | 0.00% |
includes/metaboxes/images/ui-bg_highlight-soft_75_cccccc_1x100.png | 0.10KB | 0.17KB | 0.00% |
includes/metaboxes/images/ui-icons_2e83ff_256x240.png | 4.27KB | 4.11KB | ▼ 3.78% |