10% fv-testimonials

Code Review | FV Testimonials

WordPress plugin FV Testimonials scored10%from 54 tests.

About plugin

  • Plugin page: fv-testimonials
  • Plugin version: 1.13
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.7
  • WordPress version: 6.3.1
  • First release: Nov 10, 2010
  • Latest release: Dec 8, 2016
  • Number of updates: 25
  • Update frequency: every 93.1 days
  • Top authors: FolioVision (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /9,137 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/fv-testimonials/model/fv-testimonials-class.php+5
    Methods with the same name as their class will not be constructors in a future version of PHP; FV_Testimonials has a deprecated constructor

Server metrics [RAM: ▼1.48MB] [CPU: ▼49.34ms] Passed 4 tests

A check of server-side resources used by FV Testimonials
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.50 ▼0.957.19 ▼36.10
Dashboard /wp-admin2.52 ▼0.788.58 ▼40.22
Posts /wp-admin/edit.php2.53 ▼0.837.31 ▼37.91
Add New Post /wp-admin/post-new.php2.52 ▼3.368.11 ▼83.11
Media Library /wp-admin/upload.php2.53 ▼0.707.61 ▼28.11
All Testimonials /wp-admin/edit.php?post_type=testimonial2.537.53
Categories /wp-admin/edit-tags.php?taxonomy=testimonial_category&post_type=testimonial2.537.17
Order /wp-admin/edit.php?post_type=testimonial&page=fv-testimonial-by-category2.538.45
Add New /wp-admin/post-new.php?post_type=testimonial2.538.30
Options /wp-admin/edit.php?post_type=testimonial&page=fv-testimonial-options22.537.96

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for FV Testimonials
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,852 ▲11713.29 ▼1.031.87 ▲0.0944.07 ▼25.56
Dashboard /wp-admin2,255 ▲644.97 ▲0.05105.34 ▼0.5341.72 ▼0.27
Posts /wp-admin/edit.php2,142 ▲562.29 ▲0.2935.67 ▼1.1233.02 ▼0.69
Add New Post /wp-admin/post-new.php1,556 ▲2323.52 ▲0.49630.99 ▼49.3035.38 ▼15.85
Media Library /wp-admin/upload.php1,434 ▲494.32 ▲0.1197.28 ▼10.8941.13 ▼6.74
All Testimonials /wp-admin/edit.php?post_type=testimonial1,1582.2438.0730.12
Categories /wp-admin/edit-tags.php?taxonomy=testimonial_category&post_type=testimonial1,3181.9729.9927.44
Order /wp-admin/edit.php?post_type=testimonial&page=fv-testimonial-by-category8652.1735.6935.50
Add New /wp-admin/post-new.php?post_type=testimonial2,5387.79171.4964.82
Options /wp-admin/edit.php?post_type=testimonial&page=fv-testimonial-options28881.8624.1226.12

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/fv-testimonials/model/fv-testimonials-class.php+5
    Methods with the same name as their class will not be constructors in a future version of PHP; FV_Testimonials has a deprecated constructor
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=fv-testimonial-options2
    • > Deprecated in wp-content/plugins/fv-testimonials/model/fv-testimonials-class.php+5
    Methods with the same name as their class will not be constructors in a future version of PHP; FV_Testimonials has a deprecated constructor

SRP 0% from 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
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/fv-testimonials/view/user/input.php
  • 19× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Warning
      require_once(FVTESTIMONIALS_ROOT/model/image-class.php): failed to open stream: No such file or directory in wp-content/plugins/fv-testimonials/model/fv-testimonials-class.php on line 3
    • > PHP Warning
      require_once(FVTESTIMONIALS_ROOTmodel/fv-testimonials-class.php): failed to open stream: No such file or directory in wp-content/plugins/fv-testimonials/controller/shortcodes.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_deactivation_hook() in wp-content/plugins/fv-testimonials/fv-testimonials.php:11
    • > PHP Notice
      Undefined variable: objFVTMain in wp-content/plugins/fv-testimonials/view/admin/options.php on line 3
    • > PHP Warning
      Use of undefined constant FVTESTIMONIALS_ROOT - assumed 'FVTESTIMONIALS_ROOT' (this will throw an Error in a future version of PHP) in wp-content/plugins/fv-testimonials/model/fv-testimonials-class.php on line 3
    • > PHP Fatal error
      require_once(): Failed opening required 'FVTESTIMONIALS_ROOTmodel/fv-testimonials-class.php' (include_path='.:/usr/share/php') in wp-content/plugins/fv-testimonials/controller/shortcodes.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fv-testimonials/controller/conversions.php:3
    • > PHP Notice
      Undefined variable: strText in wp-content/plugins/fv-testimonials/view/user/input.php on line 8
    • > PHP Fatal error
      require_once(): Failed opening required 'FVTESTIMONIALS_ROOT/model/image-class.php' (include_path='.:/usr/share/php') in wp-content/plugins/fv-testimonials/controller/backend.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/fv-testimonials/view/admin/options.php:14

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Screenshots: Screenshot #1 (FV Testimonials management) image not found
Please take inspiration from this readme.txt

fv-testimonials/fv-testimonials.php Passed 13 tests

This is the main PHP file of "FV Testimonials" version 1.13, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
34 characters long description:
Management system for testimonials

Code Analysis 97% from 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
No dangerous file extensions were detected3,219 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code
PHP125553782,466
CSS410286664
JavaScript162584
Markdown1105

PHP code 50% from 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
The following items need your attention
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 124)
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity196.00
▷ Minimum class complexity86.00
▷ Maximum class complexity306.00
Average method complexity12.82
▷ Minimum method complexity1.00
▷ Maximum method complexity124.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods33
▷ Static methods721.21%
▷ Public methods2575.76%
▷ Protected methods00.00%
▷ Private methods824.24%
Functions52
▷ Named functions52100.00%
▷ Anonymous functions00.00%
Constants17
▷ Global constants741.18%
▷ Class constants1058.82%
▷ Public constants10100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.16MB with 0.03MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
controller/cross.png0.67KB0.72KB0.00%
controller/tick.png0.81KB0.86KB0.00%
screenshot-1.png163.69KB63.58KB▼ 61.16%