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
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.03MB] [CPU: ▼1.16ms] Passed 4 tests
Server-side resources used by WP Password Protect Publication
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 39.00 ▲3.90 |
Dashboard /wp-admin | 3.34 ▲0.03 | 48.73 ▲0.67 |
Posts /wp-admin/edit.php | 3.39 ▲0.03 | 43.82 ▼2.05 |
Add New Post /wp-admin/post-new.php | 5.92 ▲0.03 | 81.14 ▼7.14 |
Media Library /wp-admin/upload.php | 3.26 ▲0.03 | 34.86 ▲4.62 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
can_compress_scripts |
widget_recent-comments |
widget_theysaidso_widget |
db_upgraded |
theysaidso_admin_options |
Browser metrics Passed 4 tests
WP Password Protect Publication: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲28 | 14.74 ▲0.37 | 1.80 ▲0.19 | 53.12 ▲9.14 |
Dashboard /wp-admin | 2,198 ▲21 | 5.61 ▼0.00 | 94.57 ▲7.53 | 41.20 ▼2.73 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 1.96 ▼0.06 | 34.79 ▼1.29 | 34.27 ▼4.49 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.25 ▲0.12 | 672.16 ▼14.49 | 53.91 ▼7.05 |
Media Library /wp-admin/upload.php | 1,400 ▲6 | 4.17 ▲0.06 | 94.83 ▼6.39 | 41.72 ▼4.25 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
- Zombie WordPress options were found after uninstall: 6 options
- can_compress_scripts
- widget_recent-comments
- theysaidso_admin_options
- widget_theysaidso_widget
- db_upgraded
- widget_recent-posts
Smoke tests 75% 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 50% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
- 4× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
require_once(): Failed opening required '/tmp/wordpress-tests-lib/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-password-protect-publication/tests/bootstrap.php on line 14
- > PHP Warning
require_once(/tmp/wordpress-tests-lib/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/wp-password-protect-publication/tests/bootstrap.php on line 14
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/wp-password-protect-publication/tests/test-sample.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_password_protect_publication\\is_admin() in wp-content/plugins/wp-password-protect-publication/wp-password-protect-publication.php:28
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
2 plugin tags: password, protect publication
wp-password-protect-publication/wp-password-protect-publication.php 85% from 13 tests
The entry point to "WP Password Protect Publication" version 1.0.2 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
- Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase
- Domain Path: The domain path folder was not found ("/languages")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin288 lines of code in 8 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 33 | 67 | 104 |
Bourne Shell | 1 | 19 | 6 | 93 |
JavaScript | 1 | 8 | 1 | 44 |
YAML | 1 | 7 | 0 | 22 |
XML | 1 | 0 | 0 | 14 |
JSON | 1 | 1 | 0 | 11 |
PHP code Passed 2 tests
This is a very shot review 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.39 |
Average class complexity | 9.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 17.00 |
Average method complexity | 4.20 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 11.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 5 | |
▷ Static methods | 3 | 60.00% |
▷ Public methods | 5 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 1 | |
▷ Named functions | 1 | 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
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.PNG | 13.91KB | 6.53KB | ▼ 53.07% |
screenshot-2.PNG | 12.95KB | 6.44KB | ▼ 50.30% |