Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully
Server metrics [RAM: ▲0.03MB] [CPU: ▼142.33ms] Passed 4 tests
This is a short check of server-side resources used by Woo based Stock Bar
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.88 ▲0.16 | 32.08 ▲4.55 |
Dashboard /wp-admin | 3.09 ▲0.04 | 42.53 ▼3.75 |
Posts /wp-admin/edit.php | 3.15 ▲0.04 | 45.22 ▲0.40 |
Add New Post /wp-admin/post-new.php | 5.45 ▲0.02 | 90.90 ▼567.42 |
Media Library /wp-admin/upload.php | 3.04 ▲0.04 | 32.44 ▲1.44 |
Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Checking browser requirements for Woo based Stock Bar
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,705 ▲109 | 15.80 ▲0.27 | 8.04 ▼0.35 | 48.95 ▼3.72 |
Dashboard /wp-admin | 2,973 ▲42 | 6.06 ▲0.14 | 141.50 ▲3.40 | 107.88 ▼6.22 |
Posts /wp-admin/edit.php | 2,739 ▼0 | 2.69 ▲0.01 | 64.04 ▼5.01 | 86.50 ▼4.08 |
Add New Post /wp-admin/post-new.php | 1,500 ▼0 | 18.58 ▼0.27 | 363.75 ▼13.40 | 108.32 ▼9.83 |
Media Library /wp-admin/upload.php | 1,807 ▼0 | 5.00 ▼0.02 | 153.67 ▼9.05 | 120.33 ▲0.72 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The plugin uninstalled successfully, without leaving any zombie files or tables
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
Good news, no errors were detected
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
Please take a closer look at the following
- 1× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/woo-based-stock-bar/index.php:10
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% from 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
- Plugin Name: You should set the name of your plugin on the first line (
=== woo-based-stock-bar ===
) - Screenshots: Please add an image for screenshot #1 (Woocommerce product stock bar)
woo-based-stock-bar/index.php 92% from 13 tests
"Woo based Stock Bar" version 1.0.0'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: The principal plugin file should be the same as the plugin slug ("woo-based-stock-bar.php" instead of "index.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected378 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 31 | 23 | 319 |
CSS | 1 | 4 | 3 | 59 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.92 |
Average class complexity | 30.00 |
▷ Minimum class complexity | 30.00 |
▷ Maximum class complexity | 30.00 |
Average method complexity | 8.25 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 28.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
Woo based product stock bar.png | 1.47KB | 0.73KB | ▼ 50.30% |