89% testimonial-block

Code Review | Testimonial Gutenberg Block

WordPress plugin Testimonial Gutenberg Block scored89%from 54 tests.

About plugin

  • Plugin page: testimonial-block
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.2
  • WordPress version: 6.3.1
  • First release: Sep 28, 2019
  • Latest release: Sep 30, 2019
  • Number of updates: 11
  • Update frequency: every 0.2 days
  • Top authors: jmsthemes (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

40+ active /2,109 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.18MB] [CPU: ▼8.02ms] Passed 4 tests

This is a short check of server-side resources used by Testimonial Gutenberg Block
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1046.05 ▲5.07
Dashboard /wp-admin3.39 ▲0.0949.21 ▲0.04
Posts /wp-admin/edit.php3.50 ▲0.1544.65 ▼1.12
Add New Post /wp-admin/post-new.php4.90 ▼0.9850.73 ▼31.43
Media Library /wp-admin/upload.php3.31 ▲0.0935.19 ▲0.45

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Testimonial Gutenberg Block
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲4513.23 ▼1.132.01 ▼0.0544.86 ▼2.57
Dashboard /wp-admin2,206 ▲184.86 ▼0.01103.54 ▼5.6443.17 ▲2.24
Posts /wp-admin/edit.php2,089 ▼02.03 ▲0.0033.59 ▼3.3836.00 ▲1.74
Add New Post /wp-admin/post-new.php6,193 ▲4,67322.86 ▼0.19888.77 ▲223.0274.13 ▲22.39
Media Library /wp-admin/upload.php1,391 ▼04.21 ▼0.0996.32 ▼1.5142.44 ▼0.71

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
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: Please add descriptions for these screenshots #1, #2, #3, #4, #5, #6, #7 in testimonial-block/assets to your readme.txt
The official readme.txt is a good inspiration

testimonial-block/jms-testimonialblock.php 85% from 13 tests

The entry point to "Testimonial Gutenberg Block" version 1.0.0 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("testimonial-block.php" instead of "jms-testimonialblock.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin1,630 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
CSS3247461,144
PHP12107193468
JSON40010
JavaScript36268

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity9.29
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.81
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes7
▷ Abstract classes114.29%
▷ Concrete classes685.71%
▷ Final classes00.00%
Methods33
▷ Static methods515.15%
▷ Public methods3090.91%
▷ Protected methods26.06%
▷ Private methods13.03%
Functions5
▷ Named functions360.00%
▷ Anonymous functions240.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.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
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
assets/img/owl.video.play.png4.86KB2.74KB▼ 43.61%