Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.06MB] [CPU: ▼3.40ms] Passed 4 tests
Server-side resources used by Reviews Block for Google
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.55 ▲0.09 | 41.19 ▲4.47 |
Dashboard /wp-admin | 3.36 ▲0.06 | 60.36 ▲14.06 |
Posts /wp-admin/edit.php | 3.41 ▲0.06 | 45.14 ▼4.88 |
Add New Post /wp-admin/post-new.php | 5.95 ▲0.07 | 81.30 ▼17.18 |
Media Library /wp-admin/upload.php | 3.28 ▲0.06 | 35.80 ▲4.01 |
Server storage [IO: ▲0.70MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 88 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-posts |
can_compress_scripts |
db_upgraded |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for Reviews Block for Google
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,792 ▲31 | 14.39 ▼0.09 | 1.67 ▲0.15 | 47.46 ▲10.30 |
Dashboard /wp-admin | 2,195 ▲20 | 5.58 ▼0.14 | 81.45 ▼31.72 | 39.66 ▼6.95 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 2.00 ▲0.01 | 33.71 ▼8.76 | 35.94 ▼2.01 |
Add New Post /wp-admin/post-new.php | 6,380 ▲4,854 | 22.99 ▼0.05 | 907.73 ▲250.71 | 38.07 ▼22.47 |
Media Library /wp-admin/upload.php | 1,400 ▼0 | 4.16 ▼0.08 | 95.51 ▼0.04 | 43.13 ▲1.20 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_recent-comments
- db_upgraded
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
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
- 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/google-places-reviews/includes/admin-settings.php:21
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/google-places-reviews/includes/plugin-listing-page.php:177
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/google-places-reviews/includes/legacy/widget.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/google-places-reviews/includes/legacy/widget-form.php:14
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/google-places-reviews/google-places-reviews.php:19
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html__() in wp-content/plugins/google-places-reviews/includes/legacy/widget-frontend.php:14
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/google-places-reviews/includes/options.php:3
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: google business, google places, google reviews, reviews, google
google-places-reviews/google-places-reviews.php Passed 13 tests
"Reviews Block for Google" version 2.0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
95 characters long description:
Easily display Google business reviews and ratings with a simple and intuitive WordPress block.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected3,627 lines of code in 43 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 14 | 374 | 457 | 1,576 |
Sass | 11 | 301 | 20 | 1,450 |
JavaScript | 7 | 57 | 80 | 334 |
XML | 1 | 2 | 56 | 136 |
JSON | 3 | 0 | 0 | 100 |
SVG | 3 | 0 | 0 | 27 |
CSS | 4 | 0 | 0 | 4 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 45.50 |
▷ Minimum class complexity | 14.00 |
▷ Maximum class complexity | 77.00 |
Average method complexity | 4.56 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 46.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 | 25 | |
▷ Static methods | 2 | 8.00% |
▷ Public methods | 25 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 17 | |
▷ Named functions | 17 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
30 PNG files occupy 0.14MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
(invalid) includes/legacy/assets/images/google-stars.png | 0.00KB | 0.00KB | 0.00% |
includes/legacy/assets/images/new-window-icon.png | 0.27KB | 0.12KB | ▼ 56.20% |
includes/legacy/assets/images/review_stars.png | 0.47KB | 0.54KB | 0.00% |
build/images/blank-avatar.f6e71205.png | 0.93KB | 0.61KB | ▼ 33.76% |
includes/legacy/assets/images/powered-by-google-on-white.png | 2.08KB | 2.14KB | 0.00% |