84% wpperformancetester

Code Review | WPPerformanceTester

WordPress plugin WPPerformanceTester scored84%from 54 tests.

About plugin

  • Plugin page: wpperformancetester
  • Plugin version: 2.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.9
  • WordPress version: 6.3.1
  • First release: Nov 12, 2015
  • Latest release: Jan 26, 2022
  • Number of updates: 8
  • Update frequency: every 285.4 days
  • Top authors: kohashi (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

1,000+ active /26,134 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

An overview of server-side resources used by WPPerformanceTester
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.40 ▼8.43
Dashboard /wp-admin3.33 ▼0.0252.08 ▼12.85
Posts /wp-admin/edit.php3.44 ▲0.0950.88 ▼2.02
Add New Post /wp-admin/post-new.php5.91 ▲0.0294.63 ▼6.70
Media Library /wp-admin/upload.php3.25 ▲0.0237.16 ▼1.62
WP Performance Tester /wp-admin/tools.php?page=WPPerformanceTester_PluginSettings3.2230.24

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 18 new files
Database: no new tables, 10 new options
New WordPress options
WPPerformanceTester_Plugin__installed
can_compress_scripts
WPPerformanceTester_Plugin_CanDoSomething
widget_recent-posts
WPPerformanceTester_Plugin__version
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
db_upgraded
WPPerformanceTester_Plugin_AmAwesome

Browser metrics Passed 4 tests

WPPerformanceTester: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8313.56 ▼1.052.16 ▲0.4143.23 ▼0.61
Dashboard /wp-admin2,210 ▲225.89 ▲1.02110.06 ▲0.3040.01 ▼0.72
Posts /wp-admin/edit.php2,093 ▲42.00 ▼0.0239.84 ▼0.1935.07 ▼0.46
Add New Post /wp-admin/post-new.php1,541 ▲2223.13 ▼0.07660.31 ▼17.2755.60 ▲2.09
Media Library /wp-admin/upload.php1,395 ▲104.24 ▲0.0399.62 ▼6.4948.57 ▼0.06
WP Performance Tester /wp-admin/tools.php?page=WPPerformanceTester_PluginSettings7792.2034.4626.60

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 10 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • WPPerformanceTester_Plugin_CanDoSomething
    • theysaidso_admin_options
    • WPPerformanceTester_Plugin__installed
    • WPPerformanceTester_Plugin_AmAwesome
    • db_upgraded
    • widget_recent-posts
    • WPPerformanceTester_Plugin__version
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% 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× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/wpperformancetester/wp-performance-tester.php:67

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 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
3 plugin tags: benchmark, performance, admin

wpperformancetester/wp-performance-tester.php 85% from 13 tests

Analyzing the main PHP file in "WPPerformanceTester" version 2.0.0
Please take the time to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wpperformancetester.php" instead of "wp-performance-tester.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected1,565 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP9227580929
CSS23112591
Markdown131043
JavaScript10112

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity11.17
▷ Minimum class complexity1.00
▷ Maximum class complexity42.00
Average method complexity1.85
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes233.33%
▷ Concrete classes466.67%
▷ Final classes00.00%
Methods74
▷ Static methods00.00%
▷ Public methods4560.81%
▷ Protected methods2939.19%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/write.png2.40KB1.56KB▼ 35.15%
images/down-arrow.png0.19KB0.17KB▼ 9.38%