Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.03MB] [CPU: ▼0.54ms] Passed 4 tests
Server-side resources used by Product View Counter
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.50 ▲0.04 | 47.15 ▲2.19 |
Dashboard /wp-admin | 3.34 ▲0.04 | 50.01 ▼1.12 |
Posts /wp-admin/edit.php | 3.39 ▲0.03 | 50.98 ▲0.08 |
Add New Post /wp-admin/post-new.php | 5.92 ▲0.03 | 97.27 ▲5.26 |
Media Library /wp-admin/upload.php | 3.26 ▲0.03 | 37.08 ▼3.32 |
Product View Counter /wp-admin/admin.php?page=product-view-counter | 3.23 | 32.48 |
Server storage [IO: ▲0.11MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 10 new files
Database: 1 new table, 8 new options
New tables |
---|
wp_product_view_counter |
New WordPress options |
---|
widget_recent-posts |
db_upgraded |
can_compress_scripts |
theysaidso_admin_options |
widget_theysaidso_widget |
product-view-counter__available-to-all |
product-view-counter__count-admin |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Product View Counter
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,816 ▲55 | 14.17 ▼0.18 | 2.04 ▲0.31 | 47.10 ▲1.81 |
Dashboard /wp-admin | 2,195 ▲21 | 5.63 ▲0.06 | 100.86 ▼3.87 | 50.38 ▲5.88 |
Posts /wp-admin/edit.php | 2,100 ▲3 | 1.96 ▼0.00 | 39.27 ▲1.62 | 33.06 ▼3.49 |
Add New Post /wp-admin/post-new.php | 1,528 ▲2 | 22.96 ▼0.39 | 636.94 ▼19.85 | 50.13 ▼5.08 |
Media Library /wp-admin/upload.php | 1,400 ▼0 | 4.18 ▼0.01 | 98.03 ▼18.17 | 43.65 ▼5.58 |
Product View Counter /wp-admin/admin.php?page=product-view-counter | 825 | 2.02 | 25.89 | 28.97 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- This plugin does not fully uninstall, leaving 1 table in the database
- wp_product_view_counter
- This plugin does not fully uninstall, leaving 6 options in the database
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
- db_upgraded
Smoke tests 50% 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)
The smoke test was a success, however most plugin functionality was not tested
SRP 0% 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
- 3× PHP files output text when accessed directly:
- > /wp-content/plugins/product-view-counter/404.php
- > /wp-content/plugins/product-view-counter/view.php
- > /wp-content/plugins/product-view-counter/product-view-counter.php
- 1× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/product-view-counter/admin-contorl-form.php:6
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
- Screenshots: Please add images for these screenshots: #1 (View in single product page.), #2 (Plugin options.)
product-view-counter/product-view-counter.php Passed 13 tests
Analyzing the main PHP file in "Product View Counter" version 1.1.0
106 characters long description:
A simple plugin to keep track of your product view. Has simplified configuration options and view options.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin178 lines of code in 7 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 6 | 67 | 46 | 168 |
CSS | 1 | 3 | 4 | 10 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.21 |
Average class complexity | 14.00 |
▷ Minimum class complexity | 14.00 |
▷ Maximum class complexity | 14.00 |
Average method complexity | 2.08 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 6.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 12 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 9 | 75.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 3 | 25.00% |
Functions | 1 | |
▷ Named functions | 1 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.10MB with 0.06MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 43.82KB | 16.14KB | ▼ 63.17% |
screenshot-2.png | 57.51KB | 22.83KB | ▼ 60.31% |