Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully
Server metrics [RAM: ▲0.27MB] [CPU: ▼7.57ms] Passed 4 tests
An overview of server-side resources used by Posti Shipping
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.74 ▲0.28 | 37.11 ▼3.35 |
Dashboard /wp-admin | 3.58 ▲0.27 | 45.87 ▲0.67 |
Posts /wp-admin/edit.php | 3.63 ▲0.27 | 44.09 ▼5.76 |
Add New Post /wp-admin/post-new.php | 6.16 ▲0.27 | 79.69 ▼21.84 |
Media Library /wp-admin/upload.php | 3.50 ▲0.27 | 37.30 ▲4.98 |
Server storage [IO: ▲2.96MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 107 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-posts |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
Posti Shipping: an overview of browser usage
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,792 ▲6 | 14.17 ▼0.18 | 1.74 ▼0.19 | 39.72 ▼0.04 |
Dashboard /wp-admin | 2,198 ▲21 | 5.55 ▼0.11 | 82.21 ▼13.24 | 37.68 ▼1.71 |
Posts /wp-admin/edit.php | 2,103 ▲6 | 2.01 ▲0.03 | 33.82 ▼2.25 | 36.17 ▲4.98 |
Add New Post /wp-admin/post-new.php | 1,529 ▲3 | 23.17 ▲0.11 | 655.03 ▲8.21 | 61.99 ▲14.39 |
Media Library /wp-admin/upload.php | 1,403 ▲3 | 4.17 ▼0.05 | 95.32 ▲2.84 | 41.90 ▲2.00 |
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
- The uninstall procedure has failed, leaving 6 options in the database
- widget_theysaidso_widget
- db_upgraded
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test
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
The following issues need your attention
- 10× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/estimate-price.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/get-shipment-status.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/log-api-requests.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/list-shipping-methods.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/create-shipment.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/get-pickup-point-info.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/search-pickup-points-text.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/find-city-by-postcode.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/list-additional-services.php
- > /wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/search-pickup-points.php
- 30× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Woo_Pakettikauppa_Core\\Shipment' not found in wp-content/plugins/posti-shipping/posti_shipping/classes/class-shipment.php:5
- > PHP Fatal error
require(): Failed opening required '../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/list-shipping-methods.php on line 10
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/src/Tests/Pakettikauppa/ClientTest.php:8
- > PHP Warning
require(../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/find-city-by-postcode.php on line 5
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr__() in wp-content/plugins/posti-shipping/templates/pakettikauppa/tracking-email-txt.php:13
- > PHP Fatal error
require(): Failed opening required '../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/get-shipment-status.php on line 9
- > PHP Fatal error
require(): Failed opening required '../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/search-pickup-points-text.php on line 6
- > PHP Warning
require(../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/search-pickup-points-text.php on line 6
- > PHP Fatal error
require(): Failed opening required '../vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/get-pickup-point-info.php on line 5
- > PHP Warning
require(../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/posti-shipping/vendor/pakettikauppa/api-library/examples/get-pickup-point-info.php on line 5
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
7 plugin tags: prinetti, toimitustavat, smartpost, shipping, posti...
posti-shipping/posti-shipping.php 85% from 13 tests
"Posti Shipping" version 3.9.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
- Domain Path: The domain path is invalid: folder "/languages/" does not exist
- Text Domain: The text domain name should consist of only dashes and lowercase characters
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin13,190 lines of code in 81 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 50 | 1,623 | 2,135 | 7,989 |
PO File | 6 | 1,271 | 1,543 | 3,275 |
CSS | 7 | 84 | 13 | 808 |
JavaScript | 6 | 110 | 13 | 694 |
JSON | 3 | 1 | 0 | 159 |
XML | 3 | 35 | 64 | 118 |
Markdown | 3 | 50 | 0 | 85 |
YAML | 3 | 5 | 18 | 62 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 34.10 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 262.00 |
Average method complexity | 2.64 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 61.00 |
Code structure | ||
---|---|---|
Namespaces | 7 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 30 | |
▷ Abstract classes | 1 | 3.33% |
▷ Concrete classes | 29 | 96.67% |
▷ Final classes | 0 | 0.00% |
Methods | 563 | |
▷ Static methods | 29 | 5.15% |
▷ Public methods | 496 | 88.10% |
▷ Protected methods | 17 | 3.02% |
▷ Private methods | 50 | 8.88% |
Functions | 28 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 28 | 100.00% |
Constants | 2 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 2 | 100.00% |
▷ Public constants | 2 | 100.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
7 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
.github/travis-ci-manual-trigger.png | 19.37KB | 9.48KB | ▼ 51.07% |
assets/img/pakettikauppa-logo-black.png | 2.78KB | 1.24KB | ▼ 55.38% |
assets/img/posti-logo.png | 1.85KB | 1.05KB | ▼ 43.39% |
posti_shipping/assets/img/posti-logo.png | 1.85KB | 1.05KB | ▼ 43.39% |
.github/travis-ci-sync.png | 4.08KB | 2.59KB | ▼ 36.49% |