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
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.03MB] [CPU: ▼4.82ms] Passed 4 tests
Server-side resources used by WS Coupon Woocommerce
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 41.59 ▲0.19 |
Dashboard /wp-admin | 3.34 ▼0.00 | 48.57 ▼11.92 |
Posts /wp-admin/edit.php | 3.46 ▲0.10 | 48.32 ▼1.56 |
Add New Post /wp-admin/post-new.php | 5.94 ▲0.06 | 96.02 ▼5.29 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 33.51 ▼0.52 |
My Custom Page /wp-admin/admin.php?page=ws_two_woocommerce_slug | 3.21 | 31.63 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_recent-comments |
db_upgraded |
widget_theysaidso_widget |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for WS Coupon Woocommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,923 ▲177 | 13.40 ▼0.88 | 8.41 ▲6.37 | 41.92 ▼3.55 |
Dashboard /wp-admin | 2,215 ▲38 | 5.65 ▲0.11 | 96.25 ▲3.14 | 43.08 ▼0.77 |
Posts /wp-admin/edit.php | 2,120 ▲20 | 2.00 ▲0.03 | 40.66 ▲5.24 | 35.98 ▼2.44 |
Add New Post /wp-admin/post-new.php | 1,564 ▲35 | 18.25 ▼4.90 | 589.93 ▼90.37 | 55.50 ▼1.77 |
Media Library /wp-admin/upload.php | 1,420 ▲17 | 4.23 ▲0.03 | 96.26 ▼5.50 | 43.45 ▼4.50 |
My Custom Page /wp-admin/admin.php?page=ws_two_woocommerce_slug | 800 | 2.00 | 22.87 | 25.25 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- This plugin did not uninstall successfully, leaving 6 options in the database
- can_compress_scripts
- widget_theysaidso_widget
- widget_recent-posts
- widget_recent-comments
- db_upgraded
- theysaidso_admin_options
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
- > GET request to /wp-admin/admin.php?page=ws_two_woocommerce_slug
- > Deprecated in wp-includes/class-wp-hook.php+310
Non-static method Ws_Coupon_Subadmin_Page::adminSubMenuCallback() should not be called statically
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
Almost there! Just fix the following items
- 1× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/ws-coupon-woocommerce/admin/pages/admin-no-woocommerce.php
- 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/ws-coupon-woocommerce/ws_woocommerce.php:36
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ws-coupon-woocommerce/woocommerce/initWoo.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ws-coupon-woocommerce/admin/admin.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/ws-coupon-woocommerce/admin/pages/admin-page.php:2
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% from 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed:
- Screenshots: These screenshots lack descriptions #1, #2 in ws-coupon-woocommerce/assets to your readme.txt
- Donate link: Please fix this invalid url: "paypal.me/WPKwojciechskrzek"
ws-coupon-woocommerce/ws_woocommerce.php 92% from 13 tests
"WS Coupon Woocommerce" version 0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("ws-coupon-woocommerce.php" instead of "ws_woocommerce.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected322 lines of code in 13 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 9 | 51 | 30 | 223 |
CSS | 2 | 15 | 4 | 86 |
JavaScript | 2 | 3 | 0 | 13 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.13 |
Average class complexity | 2.60 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 6.00 |
Average method complexity | 1.67 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 5 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 5 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 12 | |
▷ Static methods | 6 | 50.00% |
▷ Public methods | 12 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
admin/assets/images/paypalme.png | 24.38KB | 9.08KB | ▼ 62.75% |