Benchmarks
Plugin footprint 83% from 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.62MB] [CPU: ▼19.27ms] Passed 4 tests
Analyzing server-side resources used by Auto Assign product to sale category
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.52 ▲0.06 | 42.83 ▼4.37 |
Dashboard /wp-admin | 3.37 ▲0.06 | 48.51 ▲0.12 |
Posts /wp-admin/edit.php | 3.48 ▲0.12 | 50.19 ▼4.47 |
Add New Post /wp-admin/post-new.php | 3.21 ▼2.67 | 36.88 ▼68.34 |
Media Library /wp-admin/upload.php | 3.29 ▲0.06 | 38.52 ▲1.64 |
Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
db_upgraded |
widget_theysaidso_widget |
widget_recent-comments |
widget_recent-posts |
Browser metrics Passed 4 tests
A check of browser resources used by Auto Assign product to sale category
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,924 ▲178 | 13.66 ▼0.72 | 5.29 ▲3.44 | 39.73 ▼1.17 |
Dashboard /wp-admin | 2,222 ▲34 | 4.86 ▼1.17 | 108.33 ▼3.35 | 42.09 ▼3.27 |
Posts /wp-admin/edit.php | 2,105 ▲16 | 2.00 ▼0.01 | 39.96 ▼2.95 | 35.29 ▼0.64 |
Add New Post /wp-admin/post-new.php | 1,548 ▲12 | 23.31 ▼0.10 | 664.66 ▲55.05 | 67.63 ▲15.32 |
Media Library /wp-admin/upload.php | 1,407 ▲19 | 4.20 ▼0.08 | 102.52 ▲6.56 | 43.13 ▼0.15 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
- This plugin did not uninstall successfully, leaving 6 options in the database
- can_compress_scripts
- widget_recent-posts
- db_upgraded
- widget_recent-comments
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected
SRP 0% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/auto-assign-product-to-sale-category/public/partials/aatsc-public-display.php
- 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/auto-assign-product-to-sale-category/admin/partials/select-cat-view.php:21
- > PHP Fatal error
Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/auto-assign-product-to-sale-category/admin/partials/aatsc-admin-display.php:24
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: sale, product category sale, adding sale product category to products, automatically populate sales product category, aatsc
auto-assign-product-to-sale-category/aatsc.php 85% from 13 tests
"Auto Assign product to sale category" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
- Text Domain: The text domain name should consist of only dashes and lowercase characters
- Main file name: The principal plugin file should be the same as the plugin slug ("auto-assign-product-to-sale-category.php" instead of "aatsc.php")
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
No dangerous file extensions were detected271 lines of code in 17 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 13 | 142 | 575 | 265 |
JavaScript | 2 | 4 | 54 | 6 |
CSS | 2 | 0 | 8 | 0 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for 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.20 |
Average class complexity | 3.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 12.00 |
Average method complexity | 1.50 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 12.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 28 | |
▷ Static methods | 2 | 7.14% |
▷ Public methods | 23 | 82.14% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 17.86% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin