Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.00MB] [CPU: ▼3.16ms] Passed 4 tests
An overview of server-side resources used by Label Percentage Discount
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.00 | 39.48 ▼3.46 |
Dashboard /wp-admin | 3.31 ▲0.01 | 51.12 ▼3.28 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 53.34 ▲0.08 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 98.35 ▼5.97 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 39.39 ▲4.10 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-posts |
theysaidso_admin_options |
db_upgraded |
widget_recent-comments |
Browser metrics Passed 4 tests
An overview of browser requirements for Label Percentage Discount
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲28 | 14.34 ▼0.06 | 1.64 ▼0.01 | 40.74 ▼5.07 |
Dashboard /wp-admin | 2,195 ▲15 | 5.59 ▼0.02 | 92.67 ▼0.75 | 41.26 ▼1.65 |
Posts /wp-admin/edit.php | 2,103 ▲3 | 2.01 ▲0.01 | 42.97 ▲5.83 | 40.95 ▲5.12 |
Add New Post /wp-admin/post-new.php | 1,537 ▲9 | 18.08 ▼5.19 | 661.55 ▼36.03 | 75.98 ▲18.77 |
Media Library /wp-admin/upload.php | 1,400 ▼3 | 4.15 ▼0.01 | 111.28 ▼1.10 | 46.70 ▲1.85 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
- This plugin does not fully uninstall, leaving 6 options in the database
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
- db_upgraded
- widget_recent-comments
- theysaidso_admin_options
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
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 fix the following items
- 2× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/wc-label-percentage-discount/admin-sconto.php:23
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wc-label-percentage-discount/sconto.php:5
- > 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 issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
- Screenshots: A description for screenshot #2 is required in wc-label-percentage-discount/assets to your readme.txt
wc-label-percentage-discount/admin-sconto.php 92% from 13 tests
The main PHP script in "Label Percentage Discount" version 1.0.0 is automatically included on every request by WordPress
The following require your attention:
- Main file name: Name the main plugin file the same as the plugin slug ("wc-label-percentage-discount.php" instead of "admin-sconto.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin60 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2 | 183 | 16 | 60 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.29 |
Average class complexity | 3.00 |
▷ Minimum class complexity | 3.00 |
▷ Maximum class complexity | 3.00 |
Average method complexity | 1.50 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.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 | 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
Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin