Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲1.10MB] [CPU: ▲12.78ms] Passed 4 tests
A check of server-side resources used by WooCommerce Square
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.57 ▲1.11 | 51.37 ▲15.50 |
Dashboard /wp-admin | 4.40 ▲1.09 | 58.64 ▲6.05 |
Posts /wp-admin/edit.php | 4.51 ▲1.15 | 60.18 ▲13.32 |
Add New Post /wp-admin/post-new.php | 6.98 ▲1.09 | 105.65 ▲16.79 |
Media Library /wp-admin/upload.php | 4.32 ▲1.09 | 51.90 ▲16.26 |
Scheduled Actions /wp-admin/tools.php?page=action-scheduler | 4.50 | 52.12 |
Server storage [IO: ▲12.23MB] [DB: ▲0.01MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 3,647 new files
Database: 4 new tables, 9 new options
New tables |
---|
wp_actionscheduler_groups |
wp_actionscheduler_logs |
wp_actionscheduler_claims |
wp_actionscheduler_actions |
New WordPress options |
---|
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
widget_recent-posts |
schema-ActionScheduler_LoggerSchema |
action_scheduler_hybrid_store_demarkation |
schema-ActionScheduler_StoreSchema |
widget_recent-comments |
can_compress_scripts |
Browser metrics Passed 4 tests
A check of browser resources used by WooCommerce Square
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,809 ▲47 | 14.67 ▲0.36 | 1.60 ▼0.10 | 37.94 ▲0.12 |
Dashboard /wp-admin | 2,214 ▲40 | 5.61 ▲0.11 | 93.44 ▲1.91 | 42.10 ▲1.33 |
Posts /wp-admin/edit.php | 2,120 ▲20 | 1.97 ▲0.02 | 42.64 ▲6.20 | 37.86 ▲2.59 |
Add New Post /wp-admin/post-new.php | 1,553 ▲27 | 24.92 ▲2.21 | 637.33 ▼60.64 | 69.84 ▲2.94 |
Media Library /wp-admin/upload.php | 1,419 ▲25 | 4.22 ▼0.05 | 101.98 ▲2.77 | 44.83 ▼0.88 |
Scheduled Actions /wp-admin/tools.php?page=action-scheduler | 1,268 | 1.83 | 23.59 | 28.01 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
- The plugin did not uninstall successfully, leaving 4 tables in the database
- wp_actionscheduler_actions
- wp_actionscheduler_claims
- wp_actionscheduler_logs
- wp_actionscheduler_groups
- This plugin did not uninstall successfully, leaving 9 options in the database
- db_upgraded
- schema-ActionScheduler_StoreSchema
- widget_theysaidso_widget
- widget_recent-posts
- widget_recent-comments
- action_scheduler_hybrid_store_demarkation
- theysaidso_admin_options
- can_compress_scripts
- schema-ActionScheduler_LoggerSchema
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test
SRP 50% 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
- 198× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Core\\Types\\Sdk\\CoreFileWrapper' not found in wp-content/plugins/woocommerce-square/vendor/square/square/src/Utils/FileWrapper.php:12
- > PHP Fatal error
Uncaught Error: Class 'Square\\Apis\\BaseApi' not found in wp-content/plugins/woocommerce-square/vendor/square/square/src/Apis/EmployeesApi.php:14
- > PHP Fatal error
Uncaught Error: Interface 'CoreInterfaces\\Core\\Request\\RequestInterface' not found in wp-content/plugins/woocommerce-square/vendor/apimatic/unirest-php/src/Request/Request.php:11
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/woocommerce-square/vendor/apimatic/unirest-php/tests/ResponseTest.php:8
- > PHP Fatal error
Uncaught Error: Interface 'ActionScheduler_Exception' not found in wp-content/plugins/woocommerce-square/vendor/woocommerce/action-scheduler/classes/ActionScheduler_InvalidActionException.php:10
- > PHP Fatal error
Uncaught Error: Class 'WC_Order' not found in wp-content/plugins/woocommerce-square/includes/WC_Order_Square.php:11
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/woocommerce-square/vendor/apimatic/core/tests/ClientTest.php:25
- > PHP Fatal error
Uncaught Error: Class 'JsonMapperTest_SimpleBase' not found in wp-content/plugins/woocommerce-square/vendor/apimatic/jsonmapper/tests/JsonMapperTest/DerivedClass.php:7
- > PHP Fatal error
Uncaught Error: Class 'Square\\Apis\\BaseApi' not found in wp-content/plugins/woocommerce-square/vendor/square/square/src/Apis/SubscriptionsApi.php:30
- > PHP Fatal error
Uncaught Error: Class 'WP_CLI_Command' not found in wp-content/plugins/woocommerce-square/vendor/woocommerce/action-scheduler/classes/WP_CLI/Migration_Command.php:22
- > 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 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
4 plugin tags: square, credit card, woocommerce, inventory sync
woocommerce-square/woocommerce-square.php 92% from 13 tests
Analyzing the main PHP file in "WooCommerce Square" version 4.3.1
The following require your attention:
- Description: Please keep the plugin description shorter than 140 characters (currently 143 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin209,093 lines of code in 3,587 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2,389 | 43,451 | 139,677 | 152,688 |
Markdown | 1,095 | 13,656 | 0 | 52,892 |
JavaScript | 42 | 320 | 163 | 1,714 |
JSON | 8 | 0 | 0 | 661 |
XML | 8 | 34 | 0 | 489 |
YAML | 12 | 36 | 7 | 380 |
reStructuredText | 1 | 156 | 144 | 224 |
SVG | 22 | 0 | 0 | 30 |
CSS | 9 | 0 | 0 | 9 |
Bourne Shell | 1 | 3 | 3 | 6 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 9.66 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 274.00 |
Average method complexity | 1.82 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 46.00 |
Code structure | ||
---|---|---|
Namespaces | 77 | |
Interfaces | 29 | |
Traits | 0 | |
Classes | 2,329 | |
▷ Abstract classes | 30 | 1.29% |
▷ Concrete classes | 2,299 | 98.71% |
▷ Final classes | 0 | 0.00% |
Methods | 19,778 | |
▷ Static methods | 1,291 | 6.53% |
▷ Public methods | 18,214 | 92.09% |
▷ Protected methods | 540 | 2.73% |
▷ Private methods | 1,024 | 5.18% |
Functions | 960 | |
▷ Named functions | 19 | 1.98% |
▷ Anonymous functions | 941 | 98.02% |
Constants | 1,526 | |
▷ Global constants | 7 | 0.46% |
▷ Class constants | 1,519 | 99.54% |
▷ Public constants | 1,518 | 99.93% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
26 compressed PNG files occupy 0.05MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/images/sample-check.png | 6.29KB | 6.96KB | 0.00% |
assets/images/card-echeck.png | 1.09KB | 1.15KB | 0.00% |
assets/images/card-switch.png | 0.64KB | 0.68KB | 0.00% |
assets/images/card-google.png | 2.32KB | 1.87KB | ▼ 19.27% |
assets/images/card-visa-electron.png | 0.94KB | 1.00KB | 0.00% |