Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
- The plugin cannot be installed
- > Deprecated in wp-content/plugins/x-cart-integration/xcart-integration.php+215
Methods with the same name as their class will not be constructors in a future version of PHP; XcartMinicartWidget has a deprecated constructor
Server metrics [RAM: ▼1.84MB] [CPU: ▼56.87ms] Passed 4 tests
Server-side resources used by X-Cart Integration
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.16 ▼1.30 | 5.26 ▼36.30 |
Dashboard /wp-admin | 2.18 ▼1.17 | 6.38 ▼52.20 |
Posts /wp-admin/edit.php | 2.18 ▼1.18 | 6.35 ▼45.76 |
Add New Post /wp-admin/post-new.php | 2.18 ▼3.71 | 7.42 ▼93.22 |
Media Library /wp-admin/upload.php | 2.18 ▼1.05 | 6.10 ▼25.90 |
Server storage [IO: ▲2.13MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 106 new files
Database: no new tables, 10 new options
New WordPress options |
---|
widget_xcartminicart |
db_upgraded |
widget_recent-posts |
widget_recent-comments |
widget_xcartcategories |
can_compress_scripts |
widget_theysaidso_widget |
xcart_store_page_id |
theysaidso_admin_options |
widget_xcartsearch |
Browser metrics Passed 4 tests
An overview of browser requirements for X-Cart Integration
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,934 ▲163 | 14.13 ▼0.45 | 35.09 ▲33.20 | 44.99 ▲2.54 |
Dashboard /wp-admin | 2,223 ▲35 | 5.82 ▲0.94 | 95.98 ▼11.62 | 39.97 ▼0.29 |
Posts /wp-admin/edit.php | 2,109 ▲20 | 2.05 ▲0.03 | 34.43 ▼2.55 | 38.38 ▲4.26 |
Add New Post /wp-admin/post-new.php | 1,531 ▼3 | 23.75 ▲0.57 | 621.70 ▼53.57 | 53.05 ▲1.73 |
Media Library /wp-admin/upload.php | 1,408 ▲20 | 4.22 ▼0.03 | 94.22 ▼6.60 | 43.60 ▲1.72 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- Uninstall procedure had uncaught errors
- > Deprecated in wp-content/plugins/x-cart-integration/xcart-integration.php+215
Methods with the same name as their class will not be constructors in a future version of PHP; XcartMinicartWidget has a deprecated constructor
- This plugin does not fully uninstall, leaving 10 options in the database
- db_upgraded
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-comments
- widget_theysaidso_widget
- xcart_store_page_id
- widget_recent-posts
- widget_xcartcategories
- widget_xcartminicart
- widget_xcartsearch
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
- 39× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Notice
Undefined variable: translate in wp-content/plugins/x-cart-integration/templates/default.php on line 9
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/x-cart-integration/templates/elements/product-browser.php on line 3
- > PHP Notice
Undefined variable: attributes in wp-content/plugins/x-cart-integration/templates/elements/product-browser.php on line 3
- > PHP Notice
Undefined variable: translate in wp-content/plugins/x-cart-integration/js/init.php on line 51
- > PHP Notice
Undefined variable: jsSrc in wp-content/plugins/x-cart-integration/js/init.php on line 34
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/x-cart-integration/templates/elements/product-grid.php on line 3
- > PHP Notice
Undefined variable: attributes in wp-content/plugins/x-cart-integration/templates/elements/product-browser.php on line 3
- > PHP Notice
Undefined variable: template in wp-content/plugins/x-cart-integration/js/init.php on line 48
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/x-cart-integration/templates/default/elements/product-browser.php on line 1
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/x-cart-integration/templates/elements/product-grid.php on line 3
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
- Tags: Please reduce the number of tags, currently 15 tag instead of maximum 10
- Screenshots: These screenshots do not have images: #1 (Page in a Wordpress blog with Product grid, X-Cart Search, and X-Cart Categories menu widgets), #2 (Single product widget), #3 (Code in admin backend of X-Cart store to insert in a text in a website), #4 (Code in a blog text from admin backend of X-Cart store), #5 (Cart with products), #6 (Checkout)
x-cart-integration/xcart-integration.php 92% from 13 tests
The main PHP script in "X-Cart Integration" version 0.3 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("x-cart-integration.php" instead of "xcart-integration.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin6,278 lines of code in 72 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 38 | 685 | 275 | 4,414 |
CSS | 7 | 88 | 131 | 1,031 |
PHP | 25 | 113 | 64 | 677 |
PO File | 1 | 51 | 0 | 112 |
SVG | 1 | 0 | 1 | 44 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.17 |
Average class complexity | 4.00 |
▷ Minimum class complexity | 4.00 |
▷ Maximum class complexity | 4.00 |
Average method complexity | 1.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 4.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 12 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 12 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 20 | |
▷ Named functions | 20 | 100.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 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
16 PNG files occupy 1.68MB with 0.65MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/btn-close.png | 0.43KB | 0.59KB | 0.00% |
screenshot-6.png | 278.07KB | 103.74KB | ▼ 62.69% |
screenshot-5.png | 94.94KB | 37.45KB | ▼ 60.55% |
templates/default/images/no_image.png | 6.63KB | 2.08KB | ▼ 68.63% |
templates/default/images/basket-icon.png | 0.53KB | 0.84KB | 0.00% |