Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▼0.02MB] [CPU: ▼297.98ms] Passed 4 tests
This is a short check of server-side resources used by Add to Cart Button Manipulation for WooCommerce
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.52 ▲0.40 | 61.38 ▲36.20 |
Dashboard /wp-admin | 3.41 ▲0.00 | 37.01 ▲0.30 |
Posts /wp-admin/edit.php | 3.64 ▲0.00 | 42.00 ▲0.18 |
Add New Post /wp-admin/post-new.php | 6.91 ▼0.09 | 99.70 ▼1,188.15 |
Media Library /wp-admin/upload.php | 3.29 ▲0.00 | 24.03 ▼4.23 |
Server storage [IO: ▲0.12MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 27 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
A check of browser resources used by Add to Cart Button Manipulation for WooCommerce
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,795 ▲51 | 15.88 ▼0.13 | 6.58 ▼0.26 | 3.27 ▲0.95 |
Dashboard /wp-admin | 2,888 ▲27 | 6.13 ▼0.06 | 111.68 ▼17.79 | 159.09 ▼2.21 |
Posts /wp-admin/edit.php | 2,688 ▲31 | 3.24 ▲0.00 | 64.95 ▲0.30 | 144.12 ▲2.94 |
Add New Post /wp-admin/post-new.php | 1,668 ▲7 | 18.55 ▲2.62 | 393.02 ▼11.39 | 162.85 ▲2.02 |
Media Library /wp-admin/upload.php | 1,701 ▲3 | 5.49 ▼0.01 | 131.47 ▼4.53 | 183.55 ▼3.19 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstall script ran successfully
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 50% 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
Almost there! Just fix the following items
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/add-to-cart-button-manipulation-for-woocommerce/public/templates/single-product/wc_atcbm_available_text.php:5
- > 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 83% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
- Screenshots: Add a description for screenshot #1 in add-to-cart-button-manipulation-for-woocommerce/assets to your readme.txt
add-to-cart-button-manipulation-for-woocommerce/wc-atcbm.php 69% from 13 tests
Analyzing the main PHP file in "Add to Cart Button Manipulation for WooCommerce" version 1.0.1
You should first fix the following items:
- Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
- Main file name: The principal plugin file should be the same as the plugin slug ("add-to-cart-button-manipulation-for-woocommerce.php" instead of "wc-atcbm.php")
- Description: Please don't use more than 140 characters for the plugin description (currently 160 characters long)
- Requires at least: The required version number did not match the one declared in readme.txt ("4.0" instead of "3.0")
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
Everything looks great! No dangerous files found in this plugin560 lines of code in 21 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 13 | 240 | 570 | 460 |
CSS | 2 | 17 | 4 | 57 |
JavaScript | 6 | 14 | 37 | 43 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.33 |
Average class complexity | 6.88 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 35.00 |
Average method complexity | 2.31 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 11.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 8 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 8 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 36 | |
▷ Static methods | 2 | 5.56% |
▷ Public methods | 31 | 86.11% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 13.89% |
Functions | 2 | |
▷ Named functions | 2 | 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 Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected