84% admin-shipping-calculator

Code Review | Admin Shipping Calculator for WooCommerce

WordPress plugin Admin Shipping Calculator for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: admin-shipping-ca...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.0
  • WordPress version: 6.3.1
  • First release: Jul 22, 2022
  • Latest release: Jul 22, 2022
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: patrickbussmann (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /831 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.10MB] [CPU: ▼8.92ms] Passed 4 tests

This is a short check of server-side resources used by Admin Shipping Calculator for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0249.70 ▲8.80
Dashboard /wp-admin3.32 ▼0.0246.80 ▼14.66
Posts /wp-admin/edit.php3.37 ▲0.0245.16 ▼0.88
Add New Post /wp-admin/post-new.php5.45 ▼0.4372.28 ▼18.51
Media Library /wp-admin/upload.php3.25 ▲0.0234.82 ▼1.64

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

An overview of browser requirements for Admin Shipping Calculator for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.74 ▲0.131.84 ▲0.0343.89 ▼0.41
Dashboard /wp-admin2,209 ▲214.89 ▼0.98103.49 ▼13.8640.16 ▼4.87
Posts /wp-admin/edit.php2,086 ▼62.05 ▲0.0833.99 ▼1.5339.18 ▲2.80
Add New Post /wp-admin/post-new.php1,542 ▲918.69 ▼4.45605.87 ▼79.2869.99 ▲7.36
Media Library /wp-admin/upload.php1,391 ▼04.29 ▲0.1293.89 ▼11.8341.19 ▼1.23

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/admin-shipping-calculator/admin-shipping-calc.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test


Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: shipping, woocommerce shipping, woocommerce calculation, admin, calculate order shipping in administration

admin-shipping-calculator/admin-shipping-calc.php 92% from 13 tests

The main PHP script in "Admin Shipping Calculator for WooCommerce" version 1.0.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("admin-shipping-calculator.php" instead of "admin-shipping-calc.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin119 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.68
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions5100.00%
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin