Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.09MB] [CPU: ▼3.47ms] Passed 4 tests
A check of server-side resources used by Random image light box
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.55 ▲0.10 | 37.65 ▼8.09 |
Dashboard /wp-admin | 3.39 ▲0.09 | 45.97 ▼0.58 |
Posts /wp-admin/edit.php | 3.50 ▲0.15 | 47.48 ▼0.66 |
Add New Post /wp-admin/post-new.php | 5.97 ▲0.09 | 84.97 ▼4.53 |
Media Library /wp-admin/upload.php | 3.31 ▲0.09 | 37.79 ▲1.94 |
Random image /wp-admin/options-general.php?page=random-image-light-box | 3.30 | 31.18 |
Server storage [IO: ▲0.29MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 25 new files
Database: 1 new table, 8 new options
New tables |
---|
wp_randomimage_lb |
New WordPress options |
---|
can_compress_scripts |
widget_recent-posts |
widget_recent-comments |
random-image-light-box |
widget_random-image-light-box |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Random image light box
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,965 ▲208 | 14.00 ▼0.75 | 10.97 ▲8.84 | 42.40 ▲1.97 |
Dashboard /wp-admin | 2,213 ▲31 | 4.85 ▼1.01 | 108.15 ▲6.54 | 38.99 ▼4.20 |
Posts /wp-admin/edit.php | 2,093 ▲4 | 2.04 ▲0.02 | 36.61 ▼0.33 | 34.18 ▼1.13 |
Add New Post /wp-admin/post-new.php | 1,517 ▼17 | 17.66 ▼5.48 | 727.19 ▲131.43 | 57.50 ▲7.62 |
Media Library /wp-admin/upload.php | 1,392 ▲7 | 4.19 ▲0.00 | 95.44 ▼9.40 | 40.20 ▼4.74 |
Random image /wp-admin/options-general.php?page=random-image-light-box | 927 | 2.05 | 27.18 | 28.89 |
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
It is recommended to fix the following
- This plugin does not fully uninstall, leaving 7 options in the database
- db_upgraded
- widget_theysaidso_widget
- widget_random-image-light-box
- widget_recent-posts
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
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)
Everything seems fine, however this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
- 4× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/random-image-light-box/random-image-light-box.php
- > /wp-content/plugins/random-image-light-box/pages/image-management-edit.php
- > /wp-content/plugins/random-image-light-box/pages/image-management-add.php
- > /wp-content/plugins/random-image-light-box/pages/image-management-show.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)
No browser errors were detected
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 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
6 plugin tags: widget, plugin, gallery, random, light box...
random-image-light-box/random-image-light-box.php Passed 13 tests
The main PHP file in "Random image light box" ver. 1.3 adds more information about the plugin and also serves as the entry point for this plugin
112 characters long description:
Random image light box plugin allows you to show one random image with on click light box effect in the website.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin1,556 lines of code in 11 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 7 | 140 | 41 | 865 |
JavaScript | 2 | 80 | 105 | 416 |
CSS | 1 | 27 | 3 | 174 |
PO File | 1 | 43 | 64 | 101 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.33 |
Average class complexity | 15.50 |
▷ Minimum class complexity | 11.00 |
▷ Maximum class complexity | 23.00 |
Average method complexity | 3.32 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 19.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 4 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 4 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 25 | |
▷ Static methods | 19 | 76.00% |
▷ Public methods | 25 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 2 | |
▷ Named functions | 2 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
4 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/close.png | 0.27KB | 0.29KB | 0.00% |
inc/image-icon.png | 2.98KB | 0.54KB | ▼ 81.86% |
images/prev.png | 1.33KB | 1.59KB | 0.00% |
images/next.png | 1.32KB | 1.58KB | 0.00% |