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.06MB] [CPU: ▼1.13ms] Passed 4 tests
Analyzing server-side resources used by VNPAY Payment gateway
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.53 ▲0.07 | 45.30 ▼1.67 |
Dashboard /wp-admin | 3.37 ▲0.06 | 56.37 ▲2.79 |
Posts /wp-admin/edit.php | 3.48 ▲0.13 | 50.37 ▲0.19 |
Add New Post /wp-admin/post-new.php | 5.95 ▲0.06 | 87.62 ▼5.84 |
Media Library /wp-admin/upload.php | 3.29 ▲0.06 | 39.69 ▲5.12 |
Server storage [IO: ▲0.29MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 27 new files
Database: no new tables, 7 new options
New WordPress options |
---|
widget_theysaidso_widget |
theysaidso_admin_options |
vnpay_settings |
widget_recent-comments |
widget_recent-posts |
can_compress_scripts |
db_upgraded |
Browser metrics Passed 4 tests
An overview of browser requirements for VNPAY Payment gateway
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲28 | 14.42 ▲1.17 | 1.77 ▼2.66 | 44.49 ▼0.99 |
Dashboard /wp-admin | 2,198 ▲21 | 5.69 ▲0.04 | 86.64 ▼11.95 | 37.34 ▼3.79 |
Posts /wp-admin/edit.php | 2,097 ▼6 | 1.99 ▲0.05 | 39.34 ▼2.79 | 33.96 ▼2.57 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.30 ▼0.18 | 686.94 ▼20.68 | 60.40 ▲8.77 |
Media Library /wp-admin/upload.php | 1,400 ▼0 | 4.27 ▲0.00 | 106.14 ▲3.91 | 45.63 ▲0.59 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
- This plugin did not uninstall successfully, leaving 7 options in the database
- theysaidso_admin_options
- db_upgraded
- widget_theysaidso_widget
- vnpay_settings
- widget_recent-comments
- can_compress_scripts
- widget_recent-posts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% 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
The following issues need your attention
- 4× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Class 'vnpay\\Responses\\vnpayResponse' not found in wp-content/plugins/vnpay-for-woocommerce/src/gateways/international/vnpayInternationalResponse.php:15
- > PHP Fatal error
Uncaught Error: Class 'WC_Payment_Gateway' not found in wp-content/plugins/vnpay-for-woocommerce/src/gateways/international/vnpayGateway.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/vnpay-for-woocommerce/vnpay.php:44
- > PHP Fatal error
Uncaught Error: Interface 'vnpay\\Facades\\FacadeResponse' not found in wp-content/plugins/vnpay-for-woocommerce/src/vnpayResponse.php:15
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
- Donate link: Please fix this invalid URI: ""
vnpay-for-woocommerce/vnpay.php 85% from 13 tests
The main file in "VNPAY Payment gateway" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
- Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("vnpay-for-woocommerce.php" instead of "vnpay.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin846 lines of code in 18 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 15 | 184 | 87 | 834 |
JSON | 2 | 0 | 0 | 11 |
Markdown | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.26 |
Average class complexity | 8.09 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 39.00 |
Average method complexity | 2.62 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 18.00 |
Code structure | ||
---|---|---|
Namespaces | 7 | |
Interfaces | 1 | |
Traits | 1 | |
Classes | 9 | |
▷ Abstract classes | 1 | 11.11% |
▷ Concrete classes | 8 | 88.89% |
▷ Final classes | 0 | 0.00% |
Methods | 55 | |
▷ Static methods | 3 | 5.45% |
▷ Public methods | 54 | 98.18% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 1 | 1.82% |
Functions | 2 | |
▷ Named functions | 1 | 50.00% |
▷ Anonymous functions | 1 | 50.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
5 PNG files occupy 0.25MB with 0.17MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
logo.png | 15.67KB | 4.36KB | ▼ 72.19% |
screenshot-1.png | 45.34KB | 15.34KB | ▼ 66.16% |
screenshot-3.png | 88.41KB | 28.91KB | ▼ 67.30% |
images/logo.png | 15.67KB | 4.36KB | ▼ 72.19% |
screenshot-2.png | 93.38KB | 30.00KB | ▼ 67.87% |