72% testimonials-reviews-showcase

Code Review | Our Testimonials Showcase

WordPress plugin Our Testimonials Showcase scored 72% from 54 tests.

About plugin

  • Plugin page: testimonials-revi...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.3.1
  • WordPress version: 5.8.1
  • First release: Jul 10, 2015
  • Latest release: Sep 22, 2015
  • Number of updates: 13
  • Update frequency: every 5.8 days
  • Top authors: smartcat (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active / 7,312 total downloads

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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.14MB] [CPU: ▼136.90ms] Passed 4 tests

Server-side resources used by Our Testimonials Showcase
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.96 ▲0.1342.43 ▲7.86
Dashboard /wp-admin3.20 ▲0.1551.17 ▲9.78
Posts /wp-admin/edit.php3.30 ▲0.2053.22 ▲7.18
Add New Post /wp-admin/post-new.php5.56 ▲0.1394.74 ▼570.02
Media Library /wp-admin/upload.php3.14 ▲0.1439.08 ▲7.39
All Testimonials /wp-admin/edit.php?post_type=testimonial3.1741.24
Add New /wp-admin/post-new.php?post_type=testimonial3.2658.52
Settings /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_settings3.1937.82
Re-Order Testimonials /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_reorder3.1336.17
Groups /wp-admin/edit-tags.php?taxonomy=testimonial_position&post_type=testimonial3.1437.05
Documentation /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_documentation3.1434.54

Server storage [IO: ▲0.41MB] [DB: ▲0.00MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 42 new files
Database: no new tables, 1 new option
New WordPress options
smartcat_testimonials_options

Browser metrics Passed 4 tests

A check of browser resources used by Our Testimonials Showcase
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,865 ▲26916.46 ▲0.8211.24 ▲1.2150.69 ▲2.71
Dashboard /wp-admin3,028 ▲946.04 ▲0.11136.36 ▼6.57107.74 ▼2.71
Posts /wp-admin/edit.php2,803 ▲642.73 ▲0.0463.96 ▼0.8585.74 ▼6.46
Add New Post /wp-admin/post-new.php1,730 ▲5815.74 ▼3.01379.47 ▲34.85112.07 ▼3.91
Media Library /wp-admin/upload.php1,868 ▲585.05 ▲0.02146.97 ▼1.39119.02 ▲1.49
All Testimonials /wp-admin/edit.php?post_type=testimonial1,4602.6773.2876.58
Add New /wp-admin/post-new.php?post_type=testimonial3,2478.98210.34151.34
Settings /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_settings2,0542.4460.7998.40
Re-Order Testimonials /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_reorder1,1882.5455.8879.91
Groups /wp-admin/edit-tags.php?taxonomy=testimonial_position&post_type=testimonial1,8072.6756.7382.26
Documentation /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_documentation1,6082.3858.56130.07

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The uninstall procedure has failed, leaving 1 option in the database
    • smartcat_testimonials_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=smartcat_testimonials_settings
    • > Notice in wp-content/plugins/testimonials-reviews-showcase/admin/options.php+243
    Undefined variable: admin_email

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
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/testimonials-reviews-showcase/admin/documentation.php
  • 10× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/testimonials-reviews-showcase/admin/setting.php:89
    • > PHP Warning
      Use of undefined constant SMARTCAT_TESTIMONIALS_URL - assumed 'SMARTCAT_TESTIMONIALS_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/testimonials-reviews-showcase/admin/documentation.php on line 293
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/testimonials-reviews-showcase/admin/setting.php:89
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/testimonials-reviews-showcase/admin/setting.php:89
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/testimonials-reviews-showcase/inc/template/stacked_list.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/testimonials-reviews-showcase/admin/setting.php:89
    • > PHP Warning
      Use of undefined constant SMARTCAT_TESTIMONIALS_URL - assumed 'SMARTCAT_TESTIMONIALS_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/testimonials-reviews-showcase/admin/documentation.php on line 180
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/testimonials-reviews-showcase/inc/template/conversation_list.php:8
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/testimonials-reviews-showcase/inc/template/centered_list.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/testimonials-reviews-showcase/inc/class/class.smartcat-testimonials.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (List Bubbles Demo), #2 (List Centered Demo), #3 (Frontend submission form ( Pro Version )), #4 (Grid ( Pro Version )), #5 (Centered Slider)
  • Tags: Please delete some tags, you are using 11 tag instead of maximum 10
You can look at the official readme.txt

testimonials-reviews-showcase/our_testimonials_showcase.php 85% from 13 tests

"Our Testimonials Showcase" version 1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("testimonials-reviews-showcase.php" instead of "our_testimonials_showcase.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected3,116 lines of code in 20 files:
LanguageFilesBlank linesComment linesLines of code
PHP10302651,259
JavaScript417245945
CSS411168792
PO File14343102
SVG10018

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity26.00
▷ Minimum class complexity26.00
▷ Maximum class complexity26.00
Average method complexity1.89
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods28
▷ Static methods310.71%
▷ Public methods2692.86%
▷ Protected methods00.00%
▷ Private methods27.14%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants250.00%
▷ Class constants250.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
inc/img/smartcat_icon.png9.31KB4.05KB▼ 56.46%
inc/script/jscolor/hv.png2.80KB7.32KB0.00%
inc/img/icon.png0.67KB0.79KB0.00%
inc/img/check.png0.35KB0.31KB▼ 9.86%
inc/img/more.png3.45KB0.63KB▼ 81.87%