Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully
Server metrics [RAM: ▲0.06MB] [CPU: ▼140.73ms] Passed 4 tests
Server-side resources used by RIU - Responsive Image Uploader
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.90 ▲0.18 | 40.09 ▲17.72 |
Dashboard /wp-admin | 3.12 ▲0.07 | 48.15 ▼0.93 |
Posts /wp-admin/edit.php | 3.17 ▲0.06 | 43.17 ▼6.79 |
Add New Post /wp-admin/post-new.php | 5.48 ▲0.04 | 96.63 ▼555.29 |
Media Library /wp-admin/upload.php | 3.06 ▲0.06 | 34.33 ▲0.11 |
Server storage [IO: ▲0.26MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 30 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
An overview of browser requirements for RIU - Responsive Image Uploader
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,717 ▲122 | 15.91 ▼0.06 | 8.85 ▲0.45 | 55.66 ▲10.23 |
Dashboard /wp-admin | 2,981 ▲47 | 6.03 ▼0.12 | 155.70 ▲0.33 | 117.56 ▲0.53 |
Posts /wp-admin/edit.php | 2,753 ▲14 | 2.71 ▲0.03 | 71.81 ▼0.54 | 91.50 ▲2.00 |
Add New Post /wp-admin/post-new.php | 1,691 ▲8 | 18.52 ▼0.04 | 389.43 ▲9.68 | 110.85 ▼11.53 |
Media Library /wp-admin/upload.php | 1,817 ▲7 | 5.07 ▲0.07 | 152.50 ▲2.85 | 126.82 ▲1.46 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstaller ran successfully
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 0% 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
Please fix the following items
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/riu-responsive-image-uploader/src/admin/page/adminMediaEdit.php
- 4× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function riu\\add_action() in wp-content/plugins/riu-responsive-image-uploader/src/Javascripts.php:33
- > PHP Fatal error
Uncaught Error: Call to undefined function riu\\add_shortcode() in wp-content/plugins/riu-responsive-image-uploader/src/Shortcode.php:92
- > PHP Fatal error
Uncaught Error: Call to undefined function riu\\add_action() in wp-content/plugins/riu-responsive-image-uploader/src/admin/MediaEdit.php:31
- > PHP Fatal error
Uncaught Error: Call to undefined function riu\\add_action() in wp-content/plugins/riu-responsive-image-uploader/src/Javascripts.php:33
- > PHP Fatal error
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 96% from 29 tests
readme.txt Passed 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
10 plugin tags: image aspect ratio, focus point, area o focus, image optimizer, responsive image...
riu-responsive-image-uploader/riu.php 92% from 13 tests
The entry point to "RIU - Responsive Image Uploader" version 1.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("riu-responsive-image-uploader.php" instead of "riu.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
Good job! No executable or dangerous file extensions detected1,033 lines of code in 12 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 2 | 23 | 43 | 542 |
PHP | 8 | 186 | 166 | 420 |
JavaScript | 2 | 24 | 13 | 71 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 8.50 |
▷ Minimum class complexity | 8.00 |
▷ Maximum class complexity | 9.00 |
Average method complexity | 3.50 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.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 | 6 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 6 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 13 | |
▷ Named functions | 13 | 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
14 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
css/images/ui-bg_highlight-soft_75_ffe45c_1x100.png | 0.32KB | 0.18KB | ▼ 42.38% |
css/images/ui-bg_flat_10_000000_40x100.png | 0.20KB | 0.08KB | ▼ 57.56% |
css/images/ui-icons_ef8c08_256x240.png | 4.44KB | 4.17KB | ▼ 6.02% |
css/images/ui-bg_glass_100_fdf5ce_1x400.png | 0.34KB | 0.16KB | ▼ 54.02% |
css/images/ui-icons_228ef1_256x240.png | 4.44KB | 4.17KB | ▼ 6.02% |