Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
These installer errors require your attention
- Install procedure had errors
- > Warning in wp-content/plugins/moco-smart-search/classes/MoCo_SmartSearch_Base.php+283
"continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?
Server metrics [RAM: ▼0.79MB] [CPU: ▼33.40ms] Passed 4 tests
Analyzing server-side resources used by Smart Search for WooCommerce
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.58 ▲0.12 | 47.62 ▲3.90 |
Dashboard /wp-admin | 3.16 ▼0.18 | 30.49 ▼33.33 |
Posts /wp-admin/edit.php | 3.16 ▼0.19 | 33.55 ▼17.25 |
Add New Post /wp-admin/post-new.php | 3.16 ▼2.72 | 30.90 ▼74.41 |
Media Library /wp-admin/upload.php | 3.16 ▼0.07 | 31.21 ▼8.62 |
Server storage [IO: ▲1.45MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 35 new files
Database: no new tables, 17 new options
New WordPress options |
---|
mocoss_setup |
mocoss_facets |
mocoss_items |
widget_recent-comments |
widget_recent-posts |
mocoss_key |
mocoss_includes |
mocoss_facet_ignores |
widget_theysaidso_widget |
db_upgraded |
... |
Browser metrics Passed 4 tests
A check of browser resources used by Smart Search for WooCommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,930 ▲159 | 14.09 ▼0.29 | 8.32 ▲6.30 | 48.64 ▲5.35 |
Dashboard /wp-admin | 2,220 ▲65 | 5.83 ▲0.13 | 102.69 ▲1.23 | 79.11 ▲38.04 |
Posts /wp-admin/edit.php | 2,097 ▲8 | 1.97 ▼0.03 | 37.48 ▼0.19 | 33.07 ▼8.10 |
Add New Post /wp-admin/post-new.php | 1,678 ▲159 | 22.13 ▼1.33 | 724.05 ▲43.45 | 58.85 ▲3.50 |
Media Library /wp-admin/upload.php | 1,399 ▲11 | 4.12 ▼0.03 | 98.11 ▼17.11 | 63.64 ▲15.51 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
- Uninstall procedure validation failed for this plugin
- > User deprecated in wp-includes/functions.php+5737
Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
- This plugin did not uninstall successfully, leaving 17 options in the database
- mocoss_key
- widget_theysaidso_widget
- mocoss_facets
- theysaidso_admin_options
- widget_recent-posts
- mocoss_autocomplete
- db_upgraded
- widget_recent-comments
- mocoss_enabled
- mocoss_setup
- ...
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
- 5× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/moco-smart-search/moco-smart-search.php
- > /wp-content/plugins/moco-smart-search/templates/header.php
- > /wp-content/plugins/moco-smart-search/templates/status.php
- > /wp-content/plugins/moco-smart-search/templates/frontend/tpl.scripts.php
- > /wp-content/plugins/moco-smart-search/templates/frontend/tpl.filters.php
- 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Class 'MoCo_SmartBase' not found in wp-content/plugins/moco-smart-search/classes/class.autocomplete.php:5
- > PHP Fatal error
Uncaught Error: Class 'MoCo_SmartSearch' not found in wp-content/plugins/moco-smart-search/classes/class.navigation.php:3
- > PHP Fatal error
Uncaught Error: Class 'MoCo_SmartBase' not found in wp-content/plugins/moco-smart-search/classes/class.smartsearch.php:5
- > PHP Fatal error
Uncaught Error: Class 'MCSmartSearch\\MoCo_SmartSearch_Base' not found in wp-content/plugins/moco-smart-search/classes/MoCo_SmartSearch.php:4
- > PHP Notice
Undefined variable: SmartSearchWP_Admin in wp-content/plugins/moco-smart-search/templates/content.php on line 2
- > PHP Notice
Undefined index: facets in wp-content/plugins/moco-smart-search/templates/frontend/tpl.filters.php on line 4
- > PHP Fatal error
Uncaught Error: Call to a member function assets() on null in wp-content/plugins/moco-smart-search/templates/content.php:2
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
- Screenshots: Please add images for these screenshots: #1 (Setup Process), #2 (SmartSearch Statistics), #3 (SmartSearch WP Settings)
moco-smart-search/moco-smart-search.php 92% from 13 tests
The principal PHP file in "Smart Search for WooCommerce" v. 1.4 is loaded by WordPress automatically on each request
You should first fix the following items:
- Description: Please keep the plugin description shorter than 140 characters (currently 179 characters long)
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
No dangerous file extensions were detected22,904 lines of code in 28 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 5 | 3,887 | 10,108 | 13,739 |
CSS | 5 | 52 | 36 | 7,145 |
PHP | 18 | 297 | 411 | 2,020 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.42 |
Average class complexity | 18.94 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 64.00 |
Average method complexity | 3.70 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 39.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 16 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 16 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 91 | |
▷ Static methods | 14 | 15.38% |
▷ Public methods | 70 | 76.92% |
▷ Protected methods | 10 | 10.99% |
▷ Private methods | 11 | 12.09% |
Functions | 5 | |
▷ Named functions | 3 | 60.00% |
▷ Anonymous functions | 2 | 40.00% |
Constants | 2 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 2 | 100.00% |
▷ Public constants | 2 | 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
6 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/gs-assets/img/sort_desc.png | 1.10KB | 0.25KB | ▼ 77.73% |
assets/gs-assets/img/sort_both.png | 1.11KB | 0.29KB | ▼ 74.12% |
assets/logox30.png | 1.25KB | 1.55KB | 0.00% |
assets/logo.png | 0.63KB | 0.87KB | 0.00% |
assets/ss-logo-full.png | 4.47KB | 3.08KB | ▼ 31.12% |