Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
- The plugin did not install without errors
- > Deprecated in wp-content/plugins/add-image-maps/includes/class-add-img-maps-activator.php+24
Non-static method Add_Img_Maps::get_plugin_name() should not be called statically
Server metrics [RAM: ▼1.96MB] [CPU: ▼47.31ms] Passed 4 tests
This is a short check of server-side resources used by Add Image Maps
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.03 ▼1.43 | 4.69 ▼34.25 |
Dashboard /wp-admin | 2.05 ▼1.26 | 6.49 ▼38.39 |
Posts /wp-admin/edit.php | 2.05 ▼1.31 | 7.04 ▼37.94 |
Add New Post /wp-admin/post-new.php | 2.05 ▼3.84 | 6.54 ▼78.65 |
Media Library /wp-admin/upload.php | 2.05 ▼1.18 | 6.90 ▼24.45 |
Add Image Maps /wp-admin/options-general.php?page=add-img-maps | 2.05 | 6.76 |
Server storage [IO: ▲0.15MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 28 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
widget_recent-comments |
widget_theysaidso_widget |
db_upgraded |
can_compress_scripts |
widget_recent-posts |
Browser metrics Passed 4 tests
A check of browser resources used by Add Image Maps
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,804 ▲15 | 14.48 ▲1.22 | 1.75 ▼0.01 | 44.61 ▲3.34 |
Dashboard /wp-admin | 2,207 ▲1 | 5.80 ▲0.95 | 105.43 ▲3.75 | 39.51 ▲2.33 |
Posts /wp-admin/edit.php | 2,096 ▲7 | 2.00 ▼0.13 | 41.82 ▲1.47 | 40.45 ▲5.46 |
Add New Post /wp-admin/post-new.php | 1,522 ▲8 | 23.47 ▲5.92 | 674.77 ▲13.96 | 59.00 ▲0.73 |
Media Library /wp-admin/upload.php | 1,389 ▲4 | 4.20 ▲0.02 | 96.02 ▼4.81 | 45.28 ▼0.08 |
Add Image Maps /wp-admin/options-general.php?page=add-img-maps | 892 | 2.03 | 29.46 | 29.17 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- This plugin cannot be uninstalled
- > Deprecated in wp-content/plugins/add-image-maps/includes/class-add-img-maps-i18n.php+25
Non-static method Add_Img_Maps::name() should not be called statically
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-posts
- widget_recent-comments
- theysaidso_admin_options
- db_upgraded
- can_compress_scripts
- widget_theysaidso_widget
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
- > GET request to /wp-admin/options-general.php?page=add-img-maps
- > Deprecated in wp-content/plugins/add-image-maps/includes/class-add-img-maps-i18n.php+25
Non-static method Add_Img_Maps::name() should not be called statically
- 5 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=add-img-maps
- > Notice in wp-content/plugins/add-image-maps/admin/partials/add-img-maps-admin-display.php+29
Trying to access array offset on value of type bool
SRP 50% 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
- 5× PHP files trigger errors when accessed directly with GET requests:
- > PHP Warning
require_once(/home/ian/wordpress-dev/trunk/tests/phpunit/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/add-image-maps/tests/bootstrap.php on line 18
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/add-image-maps/tests/class-add-img-maps-map-test.php:10
- > PHP Fatal error
Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/add-image-maps/tests/class-add-img-maps-test.php:10
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/add-image-maps/admin/partials/add-img-maps-admin-display.php:16
- > PHP Fatal error
require_once(): Failed opening required '/home/ian/wordpress-dev/trunk/tests/phpunit/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/add-image-maps/tests/bootstrap.php on line 18
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found
Optimizations
Plugin configuration 93% from 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
4 plugin tags: display, links, images, imagemaps
add-image-maps/add-img-maps.php 85% from 13 tests
This is the main PHP file of "Add Image Maps" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
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 ("add-image-maps.php" instead of "add-img-maps.php")
- Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin2,044 lines of code in 23 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 16 | 379 | 1,006 | 1,154 |
JavaScript | 3 | 206 | 483 | 745 |
Markdown | 2 | 50 | 0 | 101 |
CSS | 1 | 14 | 18 | 34 |
XML | 1 | 0 | 0 | 10 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 12.36 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 41.00 |
Average method complexity | 2.62 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 21.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 11 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 11 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 53 | |
▷ Static methods | 6 | 11.32% |
▷ Public methods | 46 | 86.79% |
▷ Protected methods | 2 | 3.77% |
▷ Private methods | 5 | 9.43% |
Functions | 8 | |
▷ Named functions | 4 | 50.00% |
▷ Anonymous functions | 4 | 50.00% |
Constants | 4 | |
▷ Global constants | 2 | 50.00% |
▷ Class constants | 2 | 50.00% |
▷ Public constants | 2 | 100.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
PNG images were not found in this plugin