72% testimonial-widgets

Code Review | WP Testimonials

WordPress plugin WP Testimonials scored72%from 54 tests.

About plugin

  • Plugin page: testimonial-widgets
  • Plugin version: 1.4.3
  • PHP compatiblity: 5.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.2
  • WordPress version: 6.3.1
  • First release: Jan 14, 2022
  • Latest release: Jul 14, 2023
  • Number of updates: 21
  • Update frequency: every 26.1 days
  • Top authors: trustindex (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

2,000+ active /10,309 total downloads

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.78MB] [CPU: ▲1.53ms] Passed 4 tests

This is a short check of server-side resources used by WP Testimonials
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.41 ▲0.9447.83 ▲9.15
Dashboard /wp-admin4.11 ▲0.8166.72 ▲16.58
Posts /wp-admin/edit.php4.17 ▲0.8152.44 ▲1.63
Add New Post /wp-admin/post-new.php6.65 ▲0.7786.36 ▼11.81
Media Library /wp-admin/upload.php3.97 ▲0.7442.50 ▲7.15
Categories /wp-admin/edit-tags.php?taxonomy=wpt-testimonial-category&post_type=wpt-testimonial3.9739.98
Setup Guide /wp-admin/admin.php?page=testimonial-widgets/tabs/setup-guide.php3.9545.76
Create Widgets /wp-admin/admin.php?page=testimonial-widgets/tabs/index-widget.php3.9937.47
hidden Create Widget /wp-admin/admin.php?page=testimonial-widgets/tabs/create-widget.php4.3241.66
Rate Us /wp-admin/admin.php?page=testimonial-widgets/tabs/rate-us.php3.9437.96
My Testimonials /wp-admin/edit.php?post_type=wpt-testimonial4.0344.65

Server storage [IO: ▲1.29MB] [DB: ▲0.01MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 113 new files
Database: 1 new table, 8 new options
New tables
wp_trustindex_testimonials_widgets
New WordPress options
wp-testimonials-visited-get-reviews
wpttst_custom_forms
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Testimonials
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,852 ▲8113.62 ▼0.805.32 ▲3.4441.69 ▼1.04
Dashboard /wp-admin2,243 ▲524.87 ▼0.16100.62 ▼1.2080.23 ▲36.07
Posts /wp-admin/edit.php2,143 ▲512.02 ▲0.0034.86 ▼2.4533.29 ▼3.91
Add New Post /wp-admin/post-new.php1,558 ▲1623.00 ▲4.79696.06 ▲51.3042.13 ▼25.81
Media Library /wp-admin/upload.php1,437 ▲494.19 ▼0.0596.64 ▼2.3881.72 ▲32.10
Categories /wp-admin/edit-tags.php?taxonomy=wpt-testimonial-category&post_type=wpt-testimonial1,4132.2733.7249.03
Setup Guide /wp-admin/admin.php?page=testimonial-widgets/tabs/setup-guide.php9752.3828.5954.25
Create Widgets /wp-admin/admin.php?page=testimonial-widgets/tabs/index-widget.php1,0312.1326.3241.38
hidden Create Widget /wp-admin/admin.php?page=testimonial-widgets/tabs/create-widget.php1,1192.1429.7658.08
Rate Us /wp-admin/admin.php?page=testimonial-widgets/tabs/rate-us.php3,0102.2342.9957.81
My Testimonials /wp-admin/edit.php?post_type=wpt-testimonial1,2332.2434.3939.63

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Smoke test failed, please fix the following
    • > GET request to /wp-admin/admin.php?page=testimonial-widgets/tabs/create-widget.php
    • > Notice in wp-content/plugins/testimonial-widgets/testimonials-plugin.class.php+4020
    Undefined property: stdClass::$auto_increment

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 6× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/testimonial-widgets/testimonial-widgets.php
    • > /wp-content/plugins/testimonial-widgets/tabs/rate-us.php
    • > /wp-content/plugins/testimonial-widgets/tabs/setup-guide.php
    • > /wp-content/plugins/testimonial-widgets/uninstall.php
    • > /wp-content/plugins/testimonial-widgets/tabs/index-widget-header.php
    • > /wp-content/plugins/testimonial-widgets/tabs/create-widget-header.php
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/testimonial-widgets/tabs/index-widget.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/testimonial-widgets/post-editor.class.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/testimonial-widgets/tabs/create-widget.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/testimonial-widgets/post-types.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Screenshots: Add descriptions for screenshots #1, #10, #2, #3, #4, #5, #6, #7, #8, #9 in testimonial-widgets/assets to your readme.txt
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
You can take inspiration from this readme.txt

testimonial-widgets/testimonial-widgets.php Passed 13 tests

The entry point to "WP Testimonials" version 1.4.3 is a PHP file that has certain tags in its header comment area
117 characters long description:
Display your Testimonials on your website fast and easily. 21 widget types, 25 widget styles available. (Free Plugin)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected9,089 lines of code in 35 files:
LanguageFilesBlank linesComment linesLines of code
PHP13671336,327
CSS91111172,180
JavaScript6408518
SVG72064

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity152.50
▷ Minimum class complexity40.00
▷ Maximum class complexity265.00
Average method complexity4.12
▷ Minimum method complexity1.00
▷ Maximum method complexity36.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods77
▷ Static methods3038.96%
▷ Public methods6584.42%
▷ Protected methods00.00%
▷ Private methods1215.58%
Functions19
▷ Named functions1473.68%
▷ Anonymous functions526.32%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
static/img/trustindex-sign-logo.png3.34KB0.59KB▼ 82.47%