Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Please fix the following installer errors
- Install procedure had errors
- > Warning in wp-includes/class-wp-hook.php+312
call_user_func_array() expects parameter 1 to be a valid callback, function 'cookies_activation_redirect' not found or invalid function name
Server metrics [RAM: ▲0.02MB] [CPU: ▼5.59ms] Passed 4 tests
A check of server-side resources used by Cookies and Policy Privacy
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.48 ▲0.02 | 36.86 ▼2.14 |
Dashboard /wp-admin | 3.33 ▲0.02 | 47.06 ▼17.85 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 48.80 ▲0.04 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.04 | 93.92 ▼2.42 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 37.26 ▲4.09 |
Server storage [IO: ▲0.30MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 21 new files
Database: 2 new tables, 6 new options
New tables |
---|
wp_cookies_color |
wp_cookies_content |
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-posts |
can_compress_scripts |
db_upgraded |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
An overview of browser requirements for Cookies and Policy Privacy
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,281 ▲535 | 13.74 ▼0.63 | 9.36 ▲7.54 | 45.98 ▲5.79 |
Dashboard /wp-admin | 2,221 ▲30 | 4.96 ▼1.09 | 113.64 ▲12.74 | 39.21 ▼0.94 |
Posts /wp-admin/edit.php | 2,104 ▲12 | 2.59 ▲0.54 | 39.10 ▼0.26 | 34.04 ▼5.51 |
Add New Post /wp-admin/post-new.php | 1,540 ▲26 | 23.79 ▲5.88 | 718.69 ▲114.83 | 58.69 ▲10.95 |
Media Library /wp-admin/upload.php | 1,400 ▲12 | 4.40 ▲0.16 | 95.62 ▼1.41 | 43.30 ▼0.32 |
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
- Zombie WordPress options were found after uninstall: 6 options
- db_upgraded
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
- can_compress_scripts
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
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/cookies-privacy-policy/includes/register.php:2
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
7 plugin tags: cookie, modal, cookies, cookie bar, cookie compliance...
cookies-privacy-policy/cookies.php 92% from 13 tests
The main PHP script in "Cookies and Policy Privacy" version 1.0.0 is automatically included on every request by WordPress
You should first fix the following items:
- Main file name: The principal plugin file should be the same as the plugin slug ("cookies-privacy-policy.php" instead of "cookies.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
There were no executable files found in this plugin1,990 lines of code in 14 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 4 | 38 | 18 | 1,574 |
PHP | 7 | 2 | 25 | 357 |
JavaScript | 3 | 6 | 0 | 59 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.29 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 6 | |
▷ Named functions | 6 | 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
PNG files should be compressed to save space and minimize bandwidth usage
5 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
img/cookies-3.png | 22.21KB | 8.16KB | ▼ 63.27% |
img/cookies-4.png | 13.87KB | 5.88KB | ▼ 57.59% |
img/cookies-1.png | 20.54KB | 7.53KB | ▼ 63.34% |
img/cookies-2.png | 22.70KB | 6.73KB | ▼ 70.33% |
img/cookies.png | 35.88KB | 14.36KB | ▼ 59.97% |