Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.03MB] [CPU: ▼6.26ms] Passed 4 tests
Server-side resources used by wp top alert bar
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 39.04 ▼7.40 |
Dashboard /wp-admin | 3.34 ▲0.03 | 43.65 ▼2.95 |
Posts /wp-admin/edit.php | 3.39 ▲0.03 | 45.95 ▲2.21 |
Add New Post /wp-admin/post-new.php | 5.94 ▲0.05 | 84.42 ▼16.89 |
Media Library /wp-admin/upload.php | 3.26 ▲0.03 | 39.77 ▲5.49 |
WP Top Alert /wp-admin/options-general.php?page=wpa_alert_settings | 3.23 | 31.09 |
Server storage [IO: ▲0.30MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 29 new files
Database: no new tables, 15 new options
New WordPress options |
---|
wpa_alert_link_txt |
wpa_alert_status |
wpa_alert_link |
wpa_alert_align |
wpa_alert_link_bgColor |
theysaidso_admin_options |
widget_recent-posts |
wpa_alert_txt |
db_upgraded |
wpa_alert_location |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for wp top alert bar
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,908 ▲162 | 13.87 ▼0.51 | 6.86 ▲4.90 | 43.07 ▲0.86 |
Dashboard /wp-admin | 2,228 ▲40 | 5.02 ▲0.11 | 103.85 ▼14.45 | 39.46 ▼4.88 |
Posts /wp-admin/edit.php | 2,119 ▲33 | 2.32 ▲0.30 | 35.24 ▼1.04 | 33.52 ▼0.54 |
Add New Post /wp-admin/post-new.php | 1,533 ▲19 | 23.39 ▲5.97 | 661.19 ▼19.17 | 44.19 ▼8.89 |
Media Library /wp-admin/upload.php | 1,410 ▲22 | 4.47 ▲0.24 | 95.92 ▼5.13 | 43.86 ▲0.09 |
WP Top Alert /wp-admin/options-general.php?page=wpa_alert_settings | 1,140 | 2.33 | 52.91 | 23.15 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
- The uninstall procedure has failed, leaving 12 options in the database
- wpa_alert_bgColor
- widget_recent-posts
- wpa_alert_align
- wpa_alert_status
- theysaidso_admin_options
- wpa_alert_link_bgColor
- wpa_alert_location
- can_compress_scripts
- widget_theysaidso_widget
- db_upgraded
- ...
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
- 2× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/wp-top-alert/public/partials/wp_top_alert-public-display.php
- > /wp-content/plugins/wp-top-alert/admin/partials/wp_top_alert-admin-display.php
- 2× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-top-alert/public/partials/wpa_view.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_settings_section() in wp-content/plugins/wp-top-alert/admin/partials/wpa_settings_patials.php:3
- > 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 90% from 29 tests
readme.txt 94% from 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
- Screenshots: These screenshots have no corresponding images in /assets: #1 (screenshot-1), #2 (screenshot-2)
wp-top-alert/wp_top_alert.php 85% from 13 tests
"wp top alert bar" version 1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
- Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wp-top-alert.php" instead of "wp_top_alert.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin642 lines of code in 20 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 14 | 174 | 475 | 449 |
CSS | 3 | 18 | 8 | 113 |
PO File | 1 | 24 | 32 | 71 |
JavaScript | 2 | 3 | 0 | 9 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.14 |
Average class complexity | 1.86 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3.00 |
Average method complexity | 1.21 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 28 | |
▷ Static methods | 2 | 7.14% |
▷ Public methods | 23 | 82.14% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 17.86% |
Functions | 13 | |
▷ Named functions | 13 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.26MB with 0.22MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
public/images/hero.png | 6.80KB | 3.63KB | ▼ 46.71% |
(invalid) screenshot-2.png | 79.00KB | 0.00KB | ▼ 100.00% |
(invalid) screenshot-1.png | 184.76KB | 0.00KB | ▼ 100.00% |