Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲0.05MB] [CPU: ▼3.43ms] Passed 4 tests
This is a short check of server-side resources used by Posts Visitors
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.50 ▲0.04 | 41.44 ▼3.46 |
Dashboard /wp-admin | 3.35 ▲0.05 | 48.49 ▲2.73 |
Posts /wp-admin/edit.php | 3.40 ▲0.05 | 48.11 ▼1.24 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.07 | 87.52 ▼10.57 |
Media Library /wp-admin/upload.php | 3.27 ▲0.05 | 34.17 ▲1.55 |
Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-comments |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for Posts Visitors
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,856 ▲121 | 13.20 ▼1.47 | 1.75 ▼0.15 | 41.01 ▼5.32 |
Dashboard /wp-admin | 2,259 ▲68 | 5.85 ▲0.97 | 94.61 ▼6.26 | 41.51 ▼0.00 |
Posts /wp-admin/edit.php | 2,122 ▲33 | 2.01 ▼0.01 | 34.58 ▼5.40 | 30.14 ▼3.44 |
Add New Post /wp-admin/post-new.php | 1,531 ▲17 | 23.56 ▲6.10 | 661.05 ▲29.81 | 54.28 ▼10.32 |
Media Library /wp-admin/upload.php | 1,411 ▲23 | 4.29 ▲0.09 | 94.45 ▼2.94 | 41.34 ▲1.67 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
- The uninstall procedure has failed, leaving 6 options in the database
- widget_theysaidso_widget
- db_upgraded
- widget_recent-posts
- theysaidso_admin_options
- widget_recent-comments
- can_compress_scripts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however 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
- 5× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/posts-visitors/includes/posts-visitors-shortcode.php
- > /wp-content/plugins/posts-visitors/includes/posts-visitors-functions.php
- > /wp-content/plugins/posts-visitors/includes/posts-visitors-settings.php
- > /wp-content/plugins/posts-visitors/posts-visitors.php
- > /wp-content/plugins/posts-visitors/includes/posts-visitors-dashboard.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
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
7 plugin tags: posts, hits, posts visitors, visitors, counter...
posts-visitors/posts-visitors.php Passed 13 tests
Analyzing the main PHP file in "Posts Visitors" version 1.0.0
72 characters long description:
A plugin allows you to display how many times the post had been visited.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected625 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 7 | 154 | 140 | 511 |
JavaScript | 2 | 14 | 4 | 60 |
CSS | 1 | 7 | 5 | 54 |
PHP code Passed 2 tests
An overview 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.24 |
Average class complexity | 6.60 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 15.00 |
Average method complexity | 2.12 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 8.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 5 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 5 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 25 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 25 | 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 | 2 | |
▷ Global constants | 2 | 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 are no PNG files in this plugin