Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.00MB] [CPU: ▼146.81ms] Passed 4 tests
A check of server-side resources used by Random Images
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.85 ▲0.12 | 28.64 ▲2.04 |
Dashboard /wp-admin | 3.07 ▲0.01 | 48.35 ▼8.28 |
Posts /wp-admin/edit.php | 3.12 ▲0.01 | 47.47 ▼0.34 |
Add New Post /wp-admin/post-new.php | 5.43 ▼0.01 | 91.66 ▼574.60 |
Media Library /wp-admin/upload.php | 3.01 ▲0.01 | 31.91 ▼4.03 |
Server storage [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
An overview of browser requirements for Random Images
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,679 ▲83 | 15.78 ▲0.30 | 8.81 ▼3.86 | 51.38 ▼2.30 |
Dashboard /wp-admin | 2,970 ▲39 | 5.97 ▲0.01 | 145.34 ▲3.65 | 112.51 ▼2.41 |
Posts /wp-admin/edit.php | 2,739 ▼0 | 2.69 ▼0.01 | 70.24 ▲4.73 | 92.21 ▼5.38 |
Add New Post /wp-admin/post-new.php | 1,683 ▼0 | 18.85 ▲0.11 | 401.80 ▲9.08 | 118.75 ▲8.11 |
Media Library /wp-admin/upload.php | 1,733 ▼74 | 5.01 ▼0.02 | 156.29 ▲6.38 | 123.74 ▼1.79 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
This plugin's uninstaller ran successfully
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
- 1× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/random-images/random-images.php:14
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side
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
3 plugin tags: random images, images, shortcode
random-images/random-images.php Passed 13 tests
The entry point to "Random Images" version 1.0 is a PHP file that has certain tags in its header comment area
75 characters long description:
Display a set of random attached images with the [random_images] shortcode.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected47 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 8 | 11 | 46 |
CSS | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 5.00 |
▷ Minimum class complexity | 5.00 |
▷ Maximum class complexity | 5.00 |
Average method complexity | 3.00 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 5.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 2 | |
▷ Static methods | 2 | 100.00% |
▷ Public methods | 2 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.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
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin