Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.00MB] [CPU: ▼168.16ms] Passed 4 tests
Analyzing server-side resources used by Convert images to media
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.84 ▲0.00 | 40.25 ▲8.39 |
Dashboard /wp-admin | 3.06 ▲0.01 | 48.82 ▲1.77 |
Posts /wp-admin/edit.php | 3.11 ▲0.01 | 46.20 ▼1.25 |
Add New Post /wp-admin/post-new.php | 5.42 ▼0.01 | 90.09 ▼673.36 |
Media Library /wp-admin/upload.php | 3.01 ▲0.00 | 33.00 ▲0.21 |
CITM /wp-admin/tools.php?page=citm | 2.98 | 27.04 |
Server storage [IO: ▲0.16MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Checking browser requirements for Convert images to media
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,708 ▲112 | 15.89 ▼0.04 | 11.12 ▲0.65 | 49.10 ▲4.08 |
Dashboard /wp-admin | 2,975 ▲44 | 5.92 ▼0.25 | 143.25 ▼20.20 | 114.49 ▲3.60 |
Posts /wp-admin/edit.php | 2,744 ▲5 | 2.70 ▼0.02 | 67.20 ▼6.78 | 100.27 ▲13.76 |
Add New Post /wp-admin/post-new.php | 1,503 ▼112 | 18.54 ▼2.97 | 396.09 ▲69.89 | 108.04 ▲6.11 |
Media Library /wp-admin/upload.php | 1,812 ▲2 | 5.03 ▼0.01 | 164.47 ▲23.45 | 118.53 ▼2.10 |
CITM /wp-admin/tools.php?page=citm | 1,108 | 2.09 | 66.58 | 70.30 |
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 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not 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
- 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/convert-image-to-media/convert-image-to-media.php:19
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
- Screenshots: Add an image for screenshot #1 (The plugin showing images to convert.)
convert-image-to-media/convert-image-to-media.php Passed 13 tests
The main PHP script in "Convert images to media" version 0.4.5 is automatically included on every request by WordPress
87 characters long description:
Looks in wp-content/uploads folder, for image files and convert them to wordpress media
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
Everything looks great! No dangerous files found in this plugin147 lines of code in 1 file:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 30 | 29 | 147 |
PHP code Passed 2 tests
A brief analysis 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.33 |
Average class complexity | 17.00 |
▷ Minimum class complexity | 17.00 |
▷ Maximum class complexity | 17.00 |
Average method complexity | 5.00 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 17.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 | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 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 | 1 | |
▷ Global constants | 1 | 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
1 PNG file occupies 0.15MB with 0.09MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 156.90KB | 61.88KB | ▼ 60.56% |