Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▼0.01MB] [CPU: ▼8.12ms] Passed 4 tests
This is a short check of server-side resources used by Swedbank Pay WooCommerce Payments
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.00 | 37.20 ▼5.45 |
Dashboard /wp-admin | 3.31 ▼0.04 | 44.89 ▼15.68 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 45.21 ▼3.73 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 93.83 ▼7.63 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 34.18 ▼1.91 |
Server storage [IO: ▲4.83MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 1,041 new files
Database: 1 new table, 7 new options
New tables |
---|
wp_payex_transactions |
New WordPress options |
---|
widget_recent-posts |
db_upgraded |
theysaidso_admin_options |
widget_theysaidso_widget |
widget_recent-comments |
woocommerce_payex_psp_version |
can_compress_scripts |
Browser metrics Passed 4 tests
Checking browser requirements for Swedbank Pay WooCommerce Payments
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,828 ▲71 | 13.34 ▼1.04 | 4.33 ▲2.19 | 44.35 ▼0.95 |
Dashboard /wp-admin | 2,206 ▲18 | 4.88 ▲0.00 | 97.62 ▼19.09 | 43.21 ▼0.69 |
Posts /wp-admin/edit.php | 2,086 ▼3 | 2.02 ▼0.04 | 36.24 ▼3.07 | 29.56 ▼3.39 |
Add New Post /wp-admin/post-new.php | 1,542 ▲28 | 23.56 ▲6.04 | 624.72 ▼57.74 | 48.80 ▼10.63 |
Media Library /wp-admin/upload.php | 1,382 ▼3 | 4.19 ▼0.06 | 98.70 ▼3.49 | 44.35 ▲2.85 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
- This plugin does not fully uninstall, leaving 1 table in the database
- wp_payex_transactions
- This plugin does not fully uninstall, leaving 7 options in the database
- db_upgraded
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
- widget_theysaidso_widget
- woocommerce_payex_psp_version
- 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)
Everything seems fine, however this is by no means an exhaustive test
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× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/swedbank-pay-payments/vendor/adci/full-name-parser/tests/bootstrap.php
- 792× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'SwedbankPay\\Core\\Data' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-woocommerce-core/src/SwedbankPay/Core/Order.php:103
- > PHP Fatal error
Uncaught Error: Interface 'SwedbankPay\\Framework\\Data\\DataObjectCollectionInterface' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Framework/DataObjectCollection.php:11
- > PHP Fatal error
Uncaught Error: Class 'TestCase' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/tests/Unit/SwedbankPayTest/Api/Service/Swish/Resource/Request/PaymentTest.php:15
- > PHP Fatal error
Uncaught Error: Class 'SwedbankPay\\Framework\\DataObjectCollection' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Api/Service/Invoice/Transaction/Resource/Collection/CaptureListCollection.php:8
- > PHP Fatal error
Uncaught Error: Class 'AcceptanceTester' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/tests/acceptance/CreditcardCept.php:5
- > PHP Fatal error
Uncaught Error: Class 'SwedbankPay\\Api\\Service\\Request' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Api/Service/MobilePay/Transaction/Request/GetTransaction.php:8
- > PHP Fatal error
Uncaught Error: Interface 'SwedbankPay\\Api\\Service\\Payment\\Transaction\\Resource\\Response\\Data\\TransactionResourceInterface' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Api/Service/Invoice/Transaction/Resource/Response/Data/CancellationInterface.php:7
- > PHP Fatal error
Uncaught Error: Class 'SwedbankPay\\Api\\Service\\Request' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Api/Service/Vipps/Transaction/Request/GetReversal.php:8
- > PHP Fatal error
Uncaught Error: Class 'TestCase' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/tests/Unit/SwedbankPayTest/Api/Service/Payment/Transaction/Resource/Response/ProblemTest.php:9
- > PHP Fatal error
Uncaught Error: Interface 'SwedbankPay\\Api\\Service\\Payment\\Transaction\\Resource\\Request\\Data\\CancellationInterface' not found in wp-content/plugins/swedbank-pay-payments/vendor/swedbank-pay/swedbank-pay-sdk-php/src/SwedbankPay/Api/Service/Vipps/Transaction/Resource/Request/Data/TransactionCancellationInterface.php:12
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found
Optimizations
Plugin configuration 86% from 29 tests
readme.txt 94% from 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
- Screenshots: These screenshots need descriptions #1, #2, #3, #4, #5, #6 in swedbank-pay-payments/assets to your readme.txt
swedbank-pay-payments/swedbank-pay-woocommerce-payments.php 77% from 13 tests
Analyzing the main PHP file in "Swedbank Pay WooCommerce Payments" version 6.4.1
Please take the time to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("swedbank-pay-payments.php" instead of "swedbank-pay-woocommerce-payments.php")
- Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
- Requires at least: Required version must match the one declared in readme.txt ("5.3" instead of "5.5.1")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected46,829 lines of code in 988 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 913 | 9,286 | 18,150 | 36,513 |
JavaScript | 33 | 167 | 843 | 3,621 |
SVG | 1 | 0 | 0 | 3,602 |
CSS | 6 | 35 | 42 | 1,029 |
JSON | 12 | 0 | 0 | 1,014 |
PO File | 2 | 222 | 486 | 464 |
Markdown | 9 | 157 | 0 | 420 |
XML | 4 | 0 | 2 | 74 |
YAML | 3 | 9 | 11 | 63 |
Sass | 1 | 1 | 0 | 11 |
INI | 2 | 0 | 2 | 9 |
Dockerfile | 1 | 3 | 2 | 6 |
Bourne Shell | 1 | 2 | 0 | 3 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.15 |
Average class complexity | 2.84 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 138.00 |
Average method complexity | 1.71 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 47.00 |
Code structure | ||
---|---|---|
Namespaces | 196 | |
Interfaces | 220 | |
Traits | 17 | |
Classes | 648 | |
▷ Abstract classes | 5 | 0.77% |
▷ Concrete classes | 643 | 99.23% |
▷ Final classes | 1 | 0.16% |
Methods | 3,275 | |
▷ Static methods | 80 | 2.44% |
▷ Public methods | 3,156 | 96.37% |
▷ Protected methods | 51 | 1.56% |
▷ Private methods | 68 | 2.08% |
Functions | 64 | |
▷ Named functions | 29 | 45.31% |
▷ Anonymous functions | 35 | 54.69% |
Constants | 772 | |
▷ Global constants | 25 | 3.24% |
▷ Class constants | 747 | 96.76% |
▷ Public constants | 747 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
13 PNG files occupy 0.43MB with 0.19MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
docs/image2.png | 9.24KB | 4.35KB | ▼ 52.89% |
assets/img/flags@2x.png | 170.28KB | 68.04KB | ▼ 60.04% |
assets/images/mobilepay.png | 11.91KB | 5.18KB | ▼ 56.52% |
assets/images/trustly.png | 1.17KB | 1.58KB | 0.00% |
docs/image3.png | 10.81KB | 5.04KB | ▼ 53.42% |