Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully
Server metrics [RAM: ▲0.00MB] [CPU: ▲1.17ms] Passed 4 tests
This is a short check of server-side resources used by Get User Role
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.46 ▲0.00 | 38.20 ▲0.04 |
Dashboard /wp-admin | 3.31 ▲0.00 | 45.53 ▲0.70 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 47.71 ▲4.59 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 99.10 ▲13.92 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 32.48 ▼0.64 |
Server storage [IO: ▲0.00MB] [DB: ▲0.07MB] Passed 3 tests
How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
theysaidso_admin_options |
widget_recent-comments |
can_compress_scripts |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Get User Role
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲3 | 14.13 ▼0.25 | 1.54 ▼0.27 | 36.30 ▼6.14 |
Dashboard /wp-admin | 2,195 ▲27 | 5.63 ▲0.05 | 93.28 ▲4.94 | 36.94 ▼3.22 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 1.98 ▲0.03 | 39.23 ▲5.23 | 35.53 ▼3.24 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.09 ▼0.10 | 654.03 ▼53.46 | 63.28 ▼0.53 |
Media Library /wp-admin/upload.php | 1,400 ▼3 | 4.15 ▼0.06 | 95.60 ▲0.61 | 40.73 ▼3.42 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-posts
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
- widget_theysaidso_widget
- widget_recent-comments
Smoke tests Passed 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test
SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
- Plugin Name: You should set the name of your plugin on the first line (
=== get-user-role ===
)
get-user-role/get_user_role.php 92% from 13 tests
"Get User Role" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("get-user-role.php" instead of "get_user_role.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
No dangerous file extensions were detected33 lines of code in 1 file:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 10 | 22 | 33 |
PHP code Passed 2 tests
This is a short overview 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.22 |
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 | 0 | |
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 | 3 | |
▷ Named functions | 3 | 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
Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin