83% acf-add-testimonials-blocks

Code Review | Testimonial Slider block using ACF

WordPress plugin Testimonial Slider block using ACF scored83%from 54 tests.

About plugin

  • Plugin page: acf-add-testimoni...
  • Plugin version: 2.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.0
  • WordPress version: 6.3.1
  • First release: Jun 16, 2020
  • Latest release: Jun 20, 2022
  • Number of updates: 9
  • Update frequency: every 81.6 days
  • Top authors: aistechnolabspvtltd (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /627 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼6.76ms] Passed 4 tests

Analyzing server-side resources used by Testimonial Slider block using ACF
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0345.15 ▲4.27
Dashboard /wp-admin3.32 ▲0.0146.45 ▼4.04
Posts /wp-admin/edit.php3.37 ▲0.0145.71 ▼3.87
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.64 ▼20.71
Media Library /wp-admin/upload.php3.24 ▲0.0136.37 ▲1.58

Server storage [IO: ▲0.62MB] [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: 13 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Testimonial Slider block using ACF
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,920 ▲17413.57 ▼0.816.62 ▲4.7743.78 ▲2.53
Dashboard /wp-admin2,206 ▲185.90 ▲1.01101.10 ▼8.5239.51 ▼1.73
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0241.03 ▲1.5938.98 ▲4.51
Add New Post /wp-admin/post-new.php1,514 ▼717.84 ▼5.45648.49 ▲25.6162.83 ▲8.44
Media Library /wp-admin/upload.php1,382 ▼94.23 ▲0.0598.50 ▼2.9242.56 ▲0.18

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/acf-add-testimonials-blocks/acftb-testimonials-blocks.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-add-testimonials-blocks/includes/acftb-block-register.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function have_rows() in wp-content/plugins/acf-add-testimonials-blocks/acftb-create-block/acftb_cstm_testimonial.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes: You can take inspiration from this readme.txt

acf-add-testimonials-blocks/acftb-testimonials-blocks.php 92% from 13 tests

The main file in "Testimonial Slider block using ACF" v. 2.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("acf-add-testimonials-blocks.php" instead of "acftb-testimonials-blocks.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin14,872 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
CSS71,6242811,498
JavaScript28513203,256
PHP3173186
Markdown116032

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin