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.11MB] [CPU: ▼7.15ms] Passed 4 tests
This is a short check of server-side resources used by Innocard Loyalty Integration for WooCommerce
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.59 ▲0.13 | 43.29 ▲2.55 |
Dashboard /wp-admin | 3.42 ▲0.08 | 54.08 ▼12.30 |
Posts /wp-admin/edit.php | 3.54 ▲0.18 | 51.03 ▼2.83 |
Add New Post /wp-admin/post-new.php | 6.01 ▲0.12 | 87.97 ▼16.03 |
Media Library /wp-admin/upload.php | 3.35 ▲0.12 | 42.37 ▲2.91 |
Server storage [IO: ▲0.26MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 31 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
can_compress_scripts |
theysaidso_admin_options |
widget_recent-comments |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Innocard Loyalty Integration for WooCommerce
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,901 ▲140 | 14.43 ▲0.05 | 2.14 ▲0.30 | 43.58 ▼0.20 |
Dashboard /wp-admin | 2,303 ▲123 | 5.57 ▼0.03 | 91.24 ▼0.85 | 75.78 ▲30.49 |
Posts /wp-admin/edit.php | 2,202 ▲102 | 1.97 ▲0.01 | 39.12 ▼2.33 | 37.47 ▲2.54 |
Add New Post /wp-admin/post-new.php | 1,630 ▲104 | 22.99 ▼0.49 | 783.90 ▲160.33 | 58.46 ▲6.37 |
Media Library /wp-admin/upload.php | 1,496 ▲96 | 4.15 ▼0.09 | 115.83 ▲6.78 | 76.36 ▲32.44 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- Zombie WordPress options detected upon uninstall: 6 options
- can_compress_scripts
- theysaidso_admin_options
- widget_recent-comments
- widget_theysaidso_widget
- widget_recent-posts
- db_upgraded
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
Good news, no errors were detected
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
The following issues need your attention
- 16× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
require_once(): Failed opening required 'WC_INNOCARD_PLUGIN_DIRincludes/WC_Innocard_Admin_Settings.php' (include_path='.:/usr/share/php') in wp-content/plugins/wc-innocard-loyalty-integration/includes/admin.php on line 3
- > PHP Warning
require_once(WC_INNOCARD_PLUGIN_DIRincludes/WC_Innocard_Admin_Settings.php): failed to open stream: No such file or directory in wp-content/plugins/wc-innocard-loyalty-integration/includes/admin.php on line 3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wc-innocard-loyalty-integration/includes/api.php:26
- > PHP Fatal error
Uncaught Error: Call to undefined function WC() in wp-content/plugins/wc-innocard-loyalty-integration/includes/checkout_form_fields.php:3
- > PHP Warning
require(WC_INNOCARD_PLUGIN_DIR/includes/checkout_form_fields.php): failed to open stream: No such file or directory in wp-content/plugins/wc-innocard-loyalty-integration/templates/form.php on line 2
- > PHP Fatal error
require(): Failed opening required 'WC_INNOCARD_PLUGIN_DIR/includes/checkout_form_fields.php' (include_path='.:/usr/share/php') in wp-content/plugins/wc-innocard-loyalty-integration/templates/form.php on line 2
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wc-innocard-loyalty-integration/includes/i18n.php:6
- > PHP Warning
Use of undefined constant WC_INNOCARD_PLUGIN_DIR - assumed 'WC_INNOCARD_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/wc-innocard-loyalty-integration/includes/admin.php on line 3
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/wc-innocard-loyalty-integration/templates/admin/views/labels.php:2
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/wc-innocard-loyalty-integration/templates/admin/views/settings.php:1
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: woocommerce, integration, innocard, fidelity, loyalty
wc-innocard-loyalty-integration/wc-innocard-integration.php 85% from 13 tests
"Innocard Loyalty Integration for WooCommerce" version 6.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wc-innocard-loyalty-integration.php" instead of "wc-innocard-integration.php")
- Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin1,319 lines of code in 25 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 20 | 282 | 152 | 1,071 |
JavaScript | 1 | 52 | 16 | 152 |
Markdown | 1 | 25 | 0 | 59 |
CSS | 2 | 2 | 0 | 34 |
SVG | 1 | 0 | 0 | 3 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.42 |
Average class complexity | 5.67 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 16.00 |
Average method complexity | 2.00 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 6 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 28 | |
▷ Static methods | 2 | 7.14% |
▷ Public methods | 25 | 89.29% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 3 | 10.71% |
Functions | 22 | |
▷ Named functions | 21 | 95.45% |
▷ Anonymous functions | 1 | 4.55% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
4 PNG files occupy 0.19MB with 0.13MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
img/loyalty512.png | 99.45KB | 24.34KB | ▼ 75.53% |
assets/screenshot-3.png | 22.51KB | 7.52KB | ▼ 66.60% |
assets/screenshot-2.png | 45.42KB | 15.12KB | ▼ 66.71% |
assets/screenshot-1.png | 25.76KB | 8.91KB | ▼ 65.43% |