Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▼1.96MB] [CPU: ▼49.72ms] Passed 4 tests
Analyzing server-side resources used by WP Cookie
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.03 ▼1.44 | 4.49 ▼32.59 |
Dashboard /wp-admin | 2.05 ▼1.26 | 5.11 ▼42.97 |
Posts /wp-admin/edit.php | 2.05 ▼1.31 | 5.55 ▼39.75 |
Add New Post /wp-admin/post-new.php | 2.05 ▼3.84 | 4.93 ▼83.55 |
Media Library /wp-admin/upload.php | 2.05 ▼1.18 | 5.96 ▼29.92 |
WP Cookie /wp-admin/options-general.php?page=wpcookie | 2.05 | 5.78 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
can_compress_scripts |
widget_recent-comments |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
WP Cookie: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,987 ▲241 | 13.89 ▼0.48 | 9.89 ▲8.30 | 49.39 ▲9.76 |
Dashboard /wp-admin | 2,229 ▲43 | 5.05 ▲0.11 | 100.27 ▼10.53 | 35.78 ▼5.85 |
Posts /wp-admin/edit.php | 2,114 ▲25 | 2.32 ▲0.20 | 35.92 ▼1.88 | 32.83 ▼2.69 |
Add New Post /wp-admin/post-new.php | 1,531 ▼2 | 17.62 ▼5.52 | 601.71 ▼75.13 | 34.08 ▼31.45 |
Media Library /wp-admin/upload.php | 1,411 ▲23 | 4.47 ▲0.25 | 105.53 ▲4.36 | 43.97 ▼0.65 |
WP Cookie /wp-admin/options-general.php?page=wpcookie | 914 | 1.97 | 28.00 | 25.44 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
- Uninstall procedure validation failed for this plugin
- > User notice in wp-includes/functions.php+5905
Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the wp-color-picker handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
- The uninstall procedure has failed, leaving 6 options in the database
- widget_theysaidso_widget
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
- > GET request to /wp-admin/options-general.php?page=wpcookie
- > User notice in wp-includes/functions.php+5905
Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the wp-color-picker handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
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
Almost there! Just fix the following items
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/wp-cookie/main.php
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)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
5 plugin tags: cookie notification, cookie, cookies, cookie notice, cookie consent
wp-cookie/main.php 92% from 13 tests
"WP Cookie" version 1.0.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("wp-cookie.php" instead of "main.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected300 lines of code in 4 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 135 | 69 | 288 |
CSS | 1 | 0 | 0 | 6 |
JavaScript | 2 | 2 | 1 | 6 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.24 |
Average class complexity | 23.00 |
▷ Minimum class complexity | 23.00 |
▷ Maximum class complexity | 23.00 |
Average method complexity | 1.92 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 13.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 | 24 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 24 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.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
PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected