Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully
Server metrics [RAM: ▲0.99MB] [CPU: ▲4.15ms] Passed 4 tests
Analyzing server-side resources used by Dynamic Pricing With Discount Rules for WooCommerce
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.44 ▲0.98 | 47.93 ▲2.95 |
Dashboard /wp-admin | 4.32 ▲1.02 | 55.13 ▲5.36 |
Posts /wp-admin/edit.php | 4.37 ▲1.02 | 49.98 ▲0.86 |
Add New Post /wp-admin/post-new.php | 6.89 ▲1.00 | 100.29 ▲7.44 |
Media Library /wp-admin/upload.php | 4.18 ▲0.95 | 43.34 ▲8.16 |
Server storage [IO: ▲2.14MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 69 new files
Database: no new tables, 7 new options
New WordPress options |
---|
awdp_version |
widget_recent-posts |
theysaidso_admin_options |
db_upgraded |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
Browser metrics Passed 4 tests
Dynamic Pricing With Discount Rules for WooCommerce: an overview of browser usage
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲31 | 14.01 ▼0.33 | 1.83 ▲0.13 | 43.18 ▲0.95 |
Dashboard /wp-admin | 2,198 ▲18 | 5.62 ▼0.04 | 84.46 ▼8.66 | 39.83 ▼4.31 |
Posts /wp-admin/edit.php | 2,103 ▲3 | 1.97 ▲0.02 | 34.94 ▼6.34 | 34.56 ▼5.83 |
Add New Post /wp-admin/post-new.php | 1,529 ▲3 | 23.59 ▲0.46 | 589.19 ▼2.79 | 59.13 ▼4.82 |
Media Library /wp-admin/upload.php | 1,406 ▲6 | 4.19 ▼0.01 | 95.97 ▼7.65 | 43.54 ▼0.66 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
- Zombie WordPress options detected upon uninstall: 7 options
- widget_recent-comments
- awdp_version
- db_upgraded
- widget_theysaidso_widget
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested
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
- 4× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-help.php
- > /wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-root.php
- > /wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-lists.php
- > /wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-settings.php
- 5× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Warning
Use of undefined constant AWDP_TOKEN - assumed 'AWDP_TOKEN' (this will throw an Error in a future version of PHP) in wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-help.php on line 1
- > PHP Warning
Use of undefined constant AWDP_TOKEN - assumed 'AWDP_TOKEN' (this will throw an Error in a future version of PHP) in wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-root.php on line 1
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/aco-woo-dynamic-pricing/start.php:27
- > PHP Warning
Use of undefined constant AWDP_TOKEN - assumed 'AWDP_TOKEN' (this will throw an Error in a future version of PHP) in wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-lists.php on line 1
- > PHP Warning
Use of undefined constant AWDP_TOKEN - assumed 'AWDP_TOKEN' (this will throw an Error in a future version of PHP) in wp-content/plugins/aco-woo-dynamic-pricing/includes/views/admin-settings.php on line 1
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
- Donate link: Invalid URI found ("")
aco-woo-dynamic-pricing/start.php 85% from 13 tests
"Dynamic Pricing With Discount Rules for WooCommerce" version 4.5.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
- Description: The description should be shorter than 140 characters (currently 152 characters long)
- Main file name: Name the main plugin file the same as the plugin slug ("aco-woo-dynamic-pricing.php" instead of "start.php")
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected8,160 lines of code in 34 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 19 | 1,505 | 1,044 | 5,477 |
JSON | 3 | 0 | 0 | 1,735 |
PO File | 1 | 244 | 244 | 524 |
CSS | 2 | 22 | 3 | 178 |
JavaScript | 4 | 14 | 37 | 153 |
SVG | 4 | 0 | 0 | 71 |
XML | 1 | 0 | 0 | 22 |
PHP code 50% from 2 tests
Analyzing cyclomatic complexity and code structure
These items need your attention
- Method cyclomatic complexity should be reduced to less than 100 (currently 293)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.70 |
Average class complexity | 134.15 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 714.00 |
Average method complexity | 13.97 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 293.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 13 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 13 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 134 | |
▷ Static methods | 5 | 3.73% |
▷ Public methods | 132 | 98.51% |
▷ Protected methods | 1 | 0.75% |
▷ Private methods | 1 | 0.75% |
Functions | 12 | |
▷ Named functions | 5 | 41.67% |
▷ Anonymous functions | 7 | 58.33% |
Constants | 13 | |
▷ Global constants | 13 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
28 PNG files occupy 0.25MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/js/images/link-go.png | 1.02KB | 0.24KB | ▼ 77.00% |
assets/js/images/plan-info.png | 19.93KB | 21.76KB | 0.00% |
assets/images/ticket_bg.png | 59.50KB | 65.99KB | 0.00% |
assets/images/delete.png | 0.65KB | 0.74KB | 0.00% |
assets/images/calendar-icon.png | 1.18KB | 0.33KB | ▼ 72.29% |