Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.03MB] [CPU: ▼11.41ms] Passed 4 tests
A check of server-side resources used by Embed Swagger UI
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.04 | 39.32 ▲0.89 |
Dashboard /wp-admin | 3.34 ▼0.00 | 47.86 ▼14.35 |
Posts /wp-admin/edit.php | 3.39 ▲0.04 | 48.37 ▼6.23 |
Add New Post /wp-admin/post-new.php | 5.98 ▲0.09 | 84.81 ▼25.09 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 37.05 ▲0.03 |
All Swaggers /wp-admin/edit.php?post_type=swagger_ui | 3.31 | 36.77 |
Add new /wp-admin/post-new.php?post_type=swagger_ui | 3.32 | 45.54 |
Server storage [IO: ▲8.29MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 32 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
db_upgraded |
widget_recent-posts |
widget_recent-comments |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for Embed Swagger UI
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,897 ▲136 | 18.28 ▲3.90 | 393.83 ▲392.18 | 43.20 ▲2.33 |
Dashboard /wp-admin | 2,234 ▲60 | 5.51 ▼0.15 | 89.47 ▼7.47 | 80.31 ▲38.14 |
Posts /wp-admin/edit.php | 2,139 ▲39 | 1.97 ▼0.06 | 35.48 ▼3.52 | 35.43 ▼3.14 |
Add New Post /wp-admin/post-new.php | 1,570 ▲44 | 18.33 ▼4.83 | 720.55 ▲23.81 | 52.23 ▼20.31 |
Media Library /wp-admin/upload.php | 1,445 ▲48 | 4.24 ▲0.03 | 99.98 ▼2.23 | 66.44 ▲17.25 |
All Swaggers /wp-admin/edit.php?post_type=swagger_ui | 1,111 | 1.91 | 28.69 | 31.83 |
Add new /wp-admin/post-new.php?post_type=swagger_ui | 1,692 | 3.56 | 62.47 | 85.74 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_theysaidso_widget
- widget_recent-comments
- db_upgraded
- widget_recent-posts
- can_compress_scripts
- theysaidso_admin_options
Smoke tests Passed 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected
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
Looking good! No server-side errors or output on direct access of PHP files
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need to be fixed:
- Requires at least: The plugin version is formatted incorrectly
embed-swagger-ui/wp-swagger-ui.php 85% from 13 tests
The main PHP script in "Embed Swagger UI" version 1.0.0 is automatically included on every request by WordPress
It is important to fix the following:
- 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
- Main file name: Name the main plugin file the same as the plugin slug ("embed-swagger-ui.php" instead of "wp-swagger-ui.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected316 lines of code in 14 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 6 | 107 | 370 | 308 |
JavaScript | 5 | 0 | 9 | 5 |
CSS | 1 | 1 | 1 | 1 |
SVG | 1 | 0 | 0 | 1 |
XML | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.23 |
Average class complexity | 5.25 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 16.00 |
Average method complexity | 1.74 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 6.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 4 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 4 | 100.00% |
▷ Final classes | 1 | 25.00% |
Methods | 23 | |
▷ Static methods | 1 | 4.35% |
▷ Public methods | 20 | 86.96% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 3 | 13.04% |
Functions | 1 | |
▷ Named functions | 1 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 6 | |
▷ Global constants | 6 | 100.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
There were not PNG files found in your plugin