Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully
Server metrics [RAM: ▲0.08MB] [CPU: ▼5.69ms] Passed 4 tests
Server-side resources used by KS Ads Widget
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.55 ▲0.09 | 39.76 ▼5.98 |
Dashboard /wp-admin | 3.38 ▲0.08 | 47.69 ▼5.17 |
Posts /wp-admin/edit.php | 3.43 ▲0.08 | 51.07 ▼1.99 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.08 | 88.58 ▼9.61 |
Media Library /wp-admin/upload.php | 3.31 ▲0.08 | 41.06 ▲1.66 |
Server storage [IO: ▲0.31MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options |
---|
theysaidso_admin_options |
widget_widget_sp_image |
widget_recent-posts |
can_compress_scripts |
widget_theysaidso_widget |
db_upgraded |
widget_recent-comments |
Browser metrics Passed 4 tests
KS Ads Widget: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,808 ▲62 | 13.71 ▼1.05 | 1.59 ▼0.86 | 38.82 ▼8.46 |
Dashboard /wp-admin | 2,206 ▲18 | 5.06 ▼0.05 | 104.07 ▼14.39 | 40.50 ▼2.86 |
Posts /wp-admin/edit.php | 2,089 ▼0 | 2.05 ▼0.09 | 34.37 ▼2.10 | 36.42 ▼1.00 |
Add New Post /wp-admin/post-new.php | 1,533 ▼0 | 23.32 ▲0.04 | 689.24 ▼13.38 | 61.60 ▲6.39 |
Media Library /wp-admin/upload.php | 1,388 ▼0 | 4.14 ▼0.06 | 110.98 ▲8.54 | 46.97 ▲4.68 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
- Zombie WordPress options were found after uninstall: 7 options
- widget_widget_sp_image
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-posts
- db_upgraded
- can_compress_scripts
- widget_recent-comments
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 no errors were found, this is by no means an exhaustive test
SRP 50% from 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
Please take a closer look at the following
- 4× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/ks-ads-widget/views/widget-admin.php
- > /wp-content/plugins/ks-ads-widget/views/widget-admin.deprecated.php
- > /wp-content/plugins/ks-ads-widget/ks-ads-widget.php
- > /wp-content/plugins/ks-ads-widget/views/widget.php
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
2 plugin tags: widget, upload image
ks-ads-widget/ks-ads-widget.php Passed 13 tests
The main file in "KS Ads Widget" v. 1.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
97 characters long description:
A simple ads widget that uses the native WordPress media manager to add ads widgets to your site.
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
Good job! No executable or dangerous file extensions detected1,035 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 6 | 103 | 186 | 565 |
CSS | 1 | 18 | 14 | 244 |
JavaScript | 3 | 55 | 57 | 226 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.25 |
Average class complexity | 41.00 |
▷ Minimum class complexity | 30.00 |
▷ Maximum class complexity | 52.00 |
Average method complexity | 4.08 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 21.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 26 | |
▷ Static methods | 3 | 11.54% |
▷ Public methods | 20 | 76.92% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 6 | 23.08% |
Functions | 1 | |
▷ Named functions | 1 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 2 | 100.00% |
▷ Public constants | 2 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
4 PNG files occupy 0.26MB with 0.20MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-2.png | 29.48KB | 7.25KB | ▼ 75.42% |
screenshot-3.png | 87.74KB | 16.55KB | ▼ 81.14% |
screenshot-1.png | 81.18KB | 21.66KB | ▼ 73.31% |
screenshot-4.png | 68.35KB | 18.86KB | ▼ 72.41% |