Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Please fix the following installer errors
- Install procedure validation failed for this plugin
- > Notice in wp-content/plugins/password-policy/src/class.db.php+24
Undefined offset: 0
Server metrics [RAM: ▲0.06MB] [CPU: ▼3.84ms] Passed 4 tests
This is a short check of server-side resources used by Password-policy
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.50 ▲0.03 | 36.39 ▼1.87 |
Dashboard /wp-admin | 3.38 ▲0.07 | 44.11 ▼4.01 |
Posts /wp-admin/edit.php | 3.49 ▲0.13 | 43.99 ▼0.81 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.07 | 90.64 ▼8.67 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 34.13 ▲1.19 |
User Lists /wp-admin/admin.php?page=pssp_display_page_user | 3.28 | 31.20 |
Password Policy /wp-admin/admin.php?page=password-policy | 3.28 | 31.06 |
Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-comments |
theysaidso_admin_options |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-posts |
Browser metrics Passed 4 tests
An overview of browser requirements for Password-policy
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,818 ▲57 | 14.14 ▼0.48 | 1.79 ▲0.35 | 42.01 ▲1.94 |
Dashboard /wp-admin | 2,224 ▲47 | 5.51 ▼0.16 | 83.03 ▼7.45 | 37.93 ▼4.79 |
Posts /wp-admin/edit.php | 2,129 ▲32 | 2.03 ▲0.06 | 37.56 ▲0.36 | 35.39 ▲2.93 |
Add New Post /wp-admin/post-new.php | 1,561 ▲33 | 18.58 ▼4.56 | 628.97 ▼54.89 | 65.87 ▲14.29 |
Media Library /wp-admin/upload.php | 1,429 ▲29 | 4.20 ▼0.08 | 99.64 ▼1.22 | 42.22 ▼3.33 |
User Lists /wp-admin/admin.php?page=pssp_display_page_user | 916 | 2.04 | 23.69 | 29.08 |
Password Policy /wp-admin/admin.php?page=password-policy | 867 | 2.01 | 25.86 | 26.86 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
- Zombie WordPress options were found after uninstall: 6 options
- db_upgraded
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- theysaidso_admin_options
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
- 6 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=pssp_display_page_user
- > User deprecated in wp-includes/functions.php+5737
Function WP_User->id was called with an argument that is deprecated since version 2.1.0! Use WP_User->ID instead.
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
- 5× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/password-policy/password-policy.php:14
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/password-policy/src/check_password_policy.php:49
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/password-policy/src/views/view_config.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/password-policy/src/admin.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/password-policy/src/views/view_admin.php:2
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
4 plugin tags: enhance, security, password, policy
password-policy/password-policy.php Passed 13 tests
"Password-policy" version 1.0.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
56 characters long description:
A plugin for enfance the password policy for each users.
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 plugin594 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 7 | 106 | 73 | 387 |
Sass | 1 | 17 | 0 | 105 |
CSS | 1 | 17 | 1 | 94 |
JavaScript | 1 | 2 | 1 | 8 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.33 |
Average class complexity | 1.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 1.00 |
Average method complexity | 1.00 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 1.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 8 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 7 | 87.50% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 1 | 12.50% |
Functions | 12 | |
▷ Named functions | 12 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin