Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully
Server metrics [RAM: ▲0.24MB] [CPU: ▼764.00ms] Passed 4 tests
Server-side resources used by Freightview for WooCommerce
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.06 ▲0.34 | 35.88 ▲14.06 |
Dashboard /wp-admin | 3.28 ▲0.23 | 42.77 ▲2.09 |
Posts /wp-admin/edit.php | 3.39 ▲0.29 | 42.44 ▼0.67 |
Add New Post /wp-admin/post-new.php | 5.64 ▲0.22 | 92.82 ▼3,044.07 |
Media Library /wp-admin/upload.php | 3.22 ▲0.22 | 29.76 ▼13.35 |
Server storage [IO: ▲0.09MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
This is an overview of browser requirements for Freightview for WooCommerce
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,650 ▲44 | 15.72 ▲0.25 | 8.16 ▼1.31 | 46.37 ▼2.22 |
Dashboard /wp-admin | 2,934 ▲81 | 5.94 ▼0.07 | 135.00 ▲0.73 | 105.25 ▼1.67 |
Posts /wp-admin/edit.php | 2,706 ▲3 | 2.69 ▲0.01 | 66.21 ▼0.86 | 88.72 ▼2.89 |
Add New Post /wp-admin/post-new.php | 1,853 ▼185 | 18.99 ▼0.45 | 363.07 ▼11.17 | 105.01 ▲2.03 |
Media Library /wp-admin/upload.php | 1,772 ▼0 | 5.02 ▲0.03 | 141.05 ▼3.95 | 110.06 ▼3.60 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled successfully, without leaving any zombie files or tables
Smoke tests 75% 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 no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
- 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_upload_dir() in wp-content/plugins/freightview-for-woocommerce/woocommerce-freightview.php:29
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: freight, shopping cart, shipping, woocommerce
freightview-for-woocommerce/woocommerce-freightview.php 77% from 13 tests
"Freightview for WooCommerce" version 1.6.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("freightview-for-woocommerce.php" instead of "woocommerce-freightview.php")
- Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
- Domain Path: The domain path points to a folder that does not exist ("/languages")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin1,568 lines of code in 6 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2 | 186 | 145 | 1,331 |
JavaScript | 2 | 17 | 0 | 137 |
CSS | 2 | 8 | 0 | 100 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.45 |
Average class complexity | 44.67 |
▷ Minimum class complexity | 5.00 |
▷ Maximum class complexity | 119.00 |
Average method complexity | 3.69 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 12.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 17 | |
▷ Static methods | 6 | 35.29% |
▷ Public methods | 15 | 88.24% |
▷ Protected methods | 1 | 5.88% |
▷ Private methods | 1 | 5.88% |
Functions | 26 | |
▷ Named functions | 20 | 76.92% |
▷ Anonymous functions | 6 | 23.08% |
Constants | 6 | |
▷ Global constants | 4 | 66.67% |
▷ Class constants | 2 | 33.33% |
▷ Public constants | 2 | 100.00% |
Plugin size Passed 1 test
Image compression Passed 1 test
Using a strong compression for your PNG files is a great way to speed-up your plugin
There are no PNG files in this plugin