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.01MB] [CPU: ▼9.19ms] Passed 4 tests
Analyzing server-side resources used by Product Badges For Woocommerce
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.00 | 39.09 ▼0.44 |
Dashboard /wp-admin | 3.31 ▼0.04 | 46.79 ▼13.21 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 41.89 ▼5.50 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 79.35 ▼17.59 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 32.73 ▼0.40 |
Add New /wp-admin/post-new.php?post_type=pbfw_product_badges | 3.04 | 24.08 |
All Product Badges /wp-admin/edit.php?post_type=pbfw_product_badges | 3.04 | 24.59 |
Server storage [IO: ▲0.22MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-posts |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
A check of browser resources used by Product Badges For Woocommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,845 ▲59 | 14.39 ▲0.01 | 1.81 ▼0.17 | 44.11 ▲5.39 |
Dashboard /wp-admin | 2,189 ▲12 | 5.66 ▲0.02 | 97.46 ▲10.10 | 44.31 ▲1.12 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 2.00 ▼0.01 | 33.93 ▼3.73 | 35.40 ▼3.35 |
Add New Post /wp-admin/post-new.php | 1,536 ▲10 | 18.06 ▼5.22 | 606.91 ▼49.37 | 63.51 ▲9.33 |
Media Library /wp-admin/upload.php | 1,400 ▼0 | 4.21 ▼0.02 | 94.46 ▼8.99 | 42.00 ▼6.56 |
Add New /wp-admin/post-new.php?post_type=pbfw_product_badges | 28 | 0.42 | 0.07 | 3.75 |
All Product Badges /wp-admin/edit.php?post_type=pbfw_product_badges | 28 | 0.42 | 0.09 | 4.04 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
- This plugin does not fully uninstall, leaving 6 options in the database
- db_upgraded
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- widget_recent-comments
- theysaidso_admin_options
Smoke tests 25% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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
The following issues need your attention
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/product-badges-for-woocommerce/product-badges-for-woocommerce.php
- 3× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/product-badges-for-woocommerce/main/resources/pbfw-load-js-css.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/product-badges-for-woocommerce/main/resources/pbfw-language.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/product-badges-for-woocommerce/main/resources/pbfw-installation-require.php:3
- > PHP Fatal error
User-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
These are user-side errors you should fix
- > GET request to /wp-admin/post-new.php?post_type=pbfw_product_badges
- > Network (severe)
wp-admin/post-new.php?post_type=pbfw_product_badges - Failed to load resource: the server responded with a status of 500 (Internal Server Error)
- > GET request to /wp-admin/edit.php?post_type=pbfw_product_badges
- > Network (severe)
wp-admin/edit.php?post_type=pbfw_product_badges - Failed to load resource: the server responded with a status of 500 (Internal Server Error)
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
- Contributors: Contributors not specified
product-badges-for-woocommerce/product-badges-for-woocommerce.php 92% from 13 tests
The entry point to "Product Badges For Woocommerce" version 1.0 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
- Domain Path: The domain path is invalid: folder "/languages" does not exist
Code Analysis Passed 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
There were no executable files found in this plugin2,258 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 6 | 92 | 30 | 1,074 |
CSS | 2 | 51 | 44 | 672 |
JavaScript | 2 | 75 | 148 | 512 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 21 | |
▷ Named functions | 21 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 3 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
4 PNG files occupy 0.11MB with 0.06MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/img/badge2.png | 33.90KB | 12.97KB | ▼ 61.75% |
assets/img/badge1.png | 16.75KB | 9.76KB | ▼ 41.76% |
assets/img/badge.png | 23.76KB | 9.51KB | ▼ 59.98% |
assets/img/badge3.png | 37.72KB | 15.55KB | ▼ 58.77% |