84% bv-pantheon-migration

Code Review | Pantheon Migrations

WordPress plugin Pantheon Migrations scored84%from 54 tests.

About plugin

Code review

54 tests

User reviews

7 reviews

Install metrics

1,000+ active /75,394 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.18MB] [CPU: ▼2.84ms] Passed 4 tests

Server-side resources used by Pantheon Migrations
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.2048.25 ▲8.65
Dashboard /wp-admin3.53 ▲0.2249.02 ▲0.36
Posts /wp-admin/edit.php3.58 ▲0.2244.96 ▼1.38
Add New Post /wp-admin/post-new.php6.04 ▲0.1684.86 ▼16.91
Media Library /wp-admin/upload.php3.39 ▲0.1644.14 ▲6.57

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

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

Browser metrics Passed 4 tests

Pantheon Migrations: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲8013.24 ▼1.191.70 ▼0.0142.50 ▼7.10
Dashboard /wp-admin2,224 ▲365.84 ▼0.00102.45 ▲4.5690.92 ▲44.44
Posts /wp-admin/edit.php2,101 ▲122.18 ▲0.1834.51 ▼1.3031.12 ▼0.20
Add New Post /wp-admin/post-new.php1,681 ▲16722.35 ▲4.85777.99 ▲70.2256.66 ▼5.19
Media Library /wp-admin/upload.php1,400 ▲154.20 ▲0.03101.47 ▼2.5672.50 ▲27.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
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • 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
The smoke test was a success, however most plugin functionality was not tested

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
Please take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/bv-pantheon-migration/admin/main_page.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: migration, pantheon

bv-pantheon-migration/pantheon.php 92% from 13 tests

Analyzing the main PHP file in "Pantheon Migrations" version 5.25
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("bv-pantheon-migration.php" instead of "pantheon.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected3,394 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
PHP23456483,355
CSS18039

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity25.87
▷ Minimum class complexity1.00
▷ Maximum class complexity98.00
Average method complexity3.40
▷ Minimum method complexity1.00
▷ Maximum method complexity54.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes23
▷ Abstract classes00.00%
▷ Concrete classes23100.00%
▷ Final classes00.00%
Methods238
▷ Static methods3213.45%
▷ Public methods23799.58%
▷ Protected methods00.00%
▷ Private methods10.42%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants112.50%
▷ Class constants787.50%
▷ Public constants7100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/logo.png6.63KB3.33KB▼ 49.68%
img/icon.png0.81KB0.76KB▼ 6.12%