Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.04MB] [CPU: ▼6.56ms] Passed 4 tests
An overview of server-side resources used by States Map US
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.05 | 36.06 ▼4.42 |
Dashboard /wp-admin | 3.35 ▲0.00 | 46.67 ▼16.29 |
Posts /wp-admin/edit.php | 3.46 ▲0.11 | 56.97 ▲13.20 |
Add New Post /wp-admin/post-new.php | 5.95 ▲0.07 | 89.86 ▼6.21 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 32.92 ▲0.68 |
Add New /wp-admin/post-new.php?post_type=states_map | 3.98 | 52.71 |
States Map US /wp-admin/edit.php?post_type=states_map | 3.31 | 44.15 |
Server storage [IO: ▲1.04MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
theysaidso_admin_options |
can_compress_scripts |
db_upgraded |
widget_theysaidso_widget |
widget_recent-comments |
Browser metrics 75% from 4 tests
Checking browser requirements for States Map US
Please improve the following
- Script duration: Total JavaScript execution time should be lower than 1,500.00ms (currently 2,331.04ms on /wp-admin/post-new.php?post_type=states_map)
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,946 ▲184 | 13.92 ▼0.43 | 8.68 ▲6.84 | 41.67 ▼3.87 |
Dashboard /wp-admin | 2,234 ▲60 | 5.80 ▲0.22 | 96.32 ▼0.99 | 42.79 ▼0.87 |
Posts /wp-admin/edit.php | 2,150 ▲47 | 2.27 ▲0.33 | 41.41 ▲2.11 | 34.45 ▼2.55 |
Add New Post /wp-admin/post-new.php | 1,564 ▲38 | 23.34 ▲0.14 | 620.77 ▼28.12 | 33.18 ▼12.94 |
Media Library /wp-admin/upload.php | 1,448 ▲48 | 4.39 ▲0.15 | 97.36 ▼14.66 | 41.75 ▼3.72 |
Add New /wp-admin/post-new.php?post_type=states_map | 16,964 | 52.48 | 2,331.04 | 138.89 |
States Map US /wp-admin/edit.php?post_type=states_map | 1,111 | 2.20 | 38.16 | 26.41 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
- The uninstall procedure has failed, leaving 6 options in the database
- widget_recent-posts
- db_upgraded
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
- widget_theysaidso_widget
Smoke tests Passed 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested
SRP Passed 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Everything seems fine, however this is by no means an exhaustive test
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: custom taxonomy, usa, map, taxonomy, posts
ymc-states-map/ymc-states-map.php 92% from 13 tests
The main PHP script in "States Map US" version 2.1 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
- Domain Path: The domain path folder was not found ("/languages")
Code Analysis 97% from 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 plugin4,234 lines of code in 20 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 11 | 309 | 283 | 3,046 |
SVG | 1 | 14 | 0 | 629 |
Sass | 3 | 42 | 2 | 407 |
JavaScript | 2 | 40 | 11 | 149 |
CSS | 2 | 2 | 2 | 2 |
Markdown | 1 | 0 | 0 | 1 |
PHP code 50% from 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
The following items need your attention
- Cyclomatic complexity of methods should be reduced to less than 100 (currently 165)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 38.44 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 166.00 |
Average method complexity | 12.20 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 165.00 |
Code structure | ||
---|---|---|
Namespaces | 4 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 9 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 9 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 31 | |
▷ Static methods | 2 | 6.45% |
▷ Public methods | 28 | 90.32% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 3 | 9.68% |
Functions | 1 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 1 | 100.00% |
Constants | 9 | |
▷ Global constants | 3 | 33.33% |
▷ Class constants | 6 | 66.67% |
▷ Public constants | 6 | 100.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.57MB with 0.28MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
includes/assets/images/bg_popup.png | 516.75KB | 260.98KB | ▼ 49.50% |
includes/assets/images/map_usa.png | 71.82KB | 37.33KB | ▼ 48.02% |