78% venngage

Code Review | Venngage Infographics

WordPress plugin Venngage Infographics scored78%from 54 tests.

About plugin

  • Plugin page: venngage
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-4.2.4
  • WordPress version: 6.3.1
  • First release: Aug 21, 2015
  • Latest release: Aug 21, 2015
  • Number of updates: 5
  • Update frequency: every 0.6 days
  • Top authors: venngage (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

100+ active /5,988 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.44MB] [CPU: ▼1.61ms] Passed 4 tests

Server-side resources used by Venngage Infographics
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.90 ▲0.4444.59 ▲0.11
Dashboard /wp-admin3.76 ▲0.4650.01 ▼0.78
Posts /wp-admin/edit.php3.81 ▲0.4652.02 ▲2.26
Add New Post /wp-admin/post-new.php6.59 ▲0.7191.07 ▼8.03
Media Library /wp-admin/upload.php3.62 ▲0.4038.67 ▲4.58

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 198 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Venngage Infographics
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,887 ▲14114.05 ▼0.339.26 ▲7.0542.23 ▼2.35
Dashboard /wp-admin2,207 ▲225.85 ▲0.85112.20 ▼10.5042.64 ▼5.32
Posts /wp-admin/edit.php2,090 ▲12.03 ▲0.0136.16 ▼2.2432.34 ▼0.50
Add New Post /wp-admin/post-new.php6,384 ▲4,86519.27 ▼3.99958.32 ▲301.39187.49 ▲132.88
Media Library /wp-admin/upload.php1,395 ▲44.23 ▲0.0198.94 ▼1.3843.57 ▼0.82

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
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/venngage/resources/public/shortcode.php
  • 18× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/venngage/resources/lib/cmb2/tests/cmb-tests-base.php:10
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/venngage/resources/public/shortcode.php on line 1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/venngage/resources/lib/cmb2/init.php:119
    • > PHP Notice
      Undefined variable: test_root in wp-content/plugins/venngage/resources/lib/cmb2/tests/bootstrap.php on line 24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/venngage/resources/lib/cmb2/bootstrap.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/venngage/resources/lib/cmb2/tests/cmb-tests-base.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/venngage/resources/lib/cmb2/tests/cmb-tests-base.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/venngage/resources/lib/cmb2/tests/cmb-tests-base.php:10
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/venngage/resources/public/shortcode.php on line 5
    • > PHP Fatal error
      require_once(): Failed opening required '/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/venngage/resources/lib/cmb2/tests/bootstrap.php on line 24

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that require attention:
  • Tags: Too many tags (12 tag instead of maximum 10); only the first 5 tags are used in your directory listing
You can look at the official readme.txt

venngage/venngage.php Passed 13 tests

The principal PHP file in "Venngage Infographics" v. 1.0.0 is loaded by WordPress automatically on each request
100 characters long description:
Create and embed your Venngage infographics, charts and data visualizations into your WordPress site

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin77,473 lines of code in 151 files:
LanguageFilesBlank linesComment linesLines of code
XML20047,741
PO File948,86111,77920,270
PHP251,3112,2164,607
CSS49645002,027
Sass9157241,079
JavaScript7223173999
Markdown41440417
YAML290148
JSON300118
Bourne Shell118767

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity28.20
▷ Minimum class complexity1.00
▷ Maximum class complexity107.00
Average method complexity2.71
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes20
▷ Abstract classes15.00%
▷ Concrete classes1995.00%
▷ Final classes00.00%
Methods318
▷ Static methods216.60%
▷ Public methods30896.86%
▷ Protected methods51.57%
▷ Private methods51.57%
Functions27
▷ Named functions27100.00%
▷ Anonymous functions00.00%
Constants18
▷ Global constants1688.89%
▷ Class constants211.11%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
21 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
resources/images/postersicon.png4.43KB2.45KB▼ 44.82%
resources/lib/cmb2/images/ui-icons_888888_256x240.png5.23KB4.11KB▼ 21.49%
resources/images/infographicsicon.png5.82KB3.12KB▼ 46.39%
resources/images/reportsicon.png3.96KB2.05KB▼ 48.20%
resources/lib/cmb2/images/ui-bg_glass_55_fbf9ee_1x400.png0.12KB0.14KB0.00%