Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▼0.01MB] [CPU: ▼292.49ms] Passed 4 tests
This is a short check of server-side resources used by WooCommerce Additional Fee
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.53 ▲0.02 | 54.09 ▲3.59 |
Dashboard /wp-admin | 3.43 ▲0.02 | 31.66 ▼0.90 |
Posts /wp-admin/edit.php | 3.65 ▲0.01 | 36.05 ▲0.11 |
Add New Post /wp-admin/post-new.php | 6.90 ▼0.07 | 95.59 ▼1,161.62 |
Media Library /wp-admin/upload.php | 3.30 ▲0.00 | 23.29 ▼7.54 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Checking browser requirements for WooCommerce Additional Fee
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,763 ▲9 | 15.86 ▲0.17 | 5.76 ▼0.31 | 2.43 ▼0.10 |
Dashboard /wp-admin | 2,892 ▲31 | 6.12 ▼0.06 | 128.34 ▼6.17 | 158.32 ▲5.00 |
Posts /wp-admin/edit.php | 2,688 ▼6 | 3.24 ▲0.01 | 64.17 ▼0.92 | 137.99 ▲1.36 |
Add New Post /wp-admin/post-new.php | 1,661 ▼0 | 16.46 ▲0.34 | 414.42 ▲17.48 | 156.49 ▲3.74 |
Media Library /wp-admin/upload.php | 1,701 ▲3 | 5.50 ▼0.02 | 137.03 ▲3.34 | 180.95 ▼10.33 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstall script ran successfully
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test
SRP 50% 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
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 add_action() in wp-content/plugins/additional-fee/additional-fee.php:20
- > 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)
There were no browser issues found
Optimizations
Plugin configuration Passed 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: cart fee, custom fee, additional charge, additional fee, custom charge...
additional-fee/additional-fee.php Passed 13 tests
The principal PHP file in "WooCommerce Additional Fee" v. 1.2.1 is loaded by WordPress automatically on each request
41 characters long description:
Add additional fee/ Discount to your cart
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected133 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 20 | 10 | 96 |
PO File | 1 | 9 | 9 | 37 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 10.00 |
▷ Minimum class complexity | 10.00 |
▷ Maximum class complexity | 10.00 |
Average method complexity | 1.90 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 10 | |
▷ Static methods | 1 | 10.00% |
▷ Public methods | 10 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.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
Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin