Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲0.09MB] [CPU: ▼142.30ms] Passed 4 tests
Server-side resources used by Canadian Nutrition Facts Label
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.93 ▲0.21 | 33.65 ▲13.46 |
Dashboard /wp-admin | 3.15 ▲0.09 | 35.89 ▼10.64 |
Posts /wp-admin/edit.php | 3.20 ▲0.09 | 35.36 ▼2.71 |
Add New Post /wp-admin/post-new.php | 5.52 ▲0.08 | 91.39 ▼550.60 |
Media Library /wp-admin/upload.php | 3.09 ▲0.09 | 30.08 ▼5.24 |
Add New /wp-admin/post-new.php?post_type=nutrition-label | 3.14 | 46.20 |
All Labels /wp-admin/edit.php?post_type=nutrition-label | 3.13 | 34.55 |
Server storage [IO: ▲0.05MB] [DB: ▲0.62MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
A check of browser resources used by Canadian Nutrition Facts Label
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,837 ▲241 | 16.61 ▲0.75 | 11.39 ▲2.15 | 46.65 ▲3.25 |
Dashboard /wp-admin | 3,001 ▲70 | 5.94 ▼0.06 | 127.91 ▼12.31 | 138.07 ▲25.35 |
Posts /wp-admin/edit.php | 2,760 ▲21 | 2.60 ▼0.08 | 63.94 ▼4.72 | 91.87 ▼2.70 |
Add New Post /wp-admin/post-new.php | 1,642 ▼30 | 21.51 ▲2.62 | 280.09 ▼110.91 | 106.69 ▼4.29 |
Media Library /wp-admin/upload.php | 1,786 ▼21 | 5.05 ▲0.03 | 129.86 ▼24.17 | 144.39 ▲27.82 |
Add New /wp-admin/post-new.php?post_type=nutrition-label | 2,355 | 3.32 | 82.92 | 100.28 |
All Labels /wp-admin/edit.php?post_type=nutrition-label | 1,473 | 2.63 | 62.99 | 71.04 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.62MB] Passed 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however 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 fix the following items
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/canadian-nutrition-facts-label/canadian-nutrition-facts-label.php:26
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: food, bilingual, nutrition labelling, nutrition facts table, canadian...
canadian-nutrition-facts-label/canadian-nutrition-facts-label.php 92% from 13 tests
"Canadian Nutrition Facts Label" version 3.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
- Description: The description should be shorter than 140 characters (currently 156 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin552 lines of code in 4 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 102 | 78 | 410 |
JavaScript | 2 | 23 | 38 | 84 |
CSS | 1 | 12 | 7 | 58 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.33 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 10 | |
▷ Named functions | 10 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.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
4 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
facts-menu-icon.png | 0.33KB | 0.22KB | ▼ 34.99% |
img/minus.png | 0.67KB | 0.61KB | ▼ 9.09% |
img/facts-menu-icon.png | 0.33KB | 0.22KB | ▼ 34.99% |
img/plus.png | 1.15KB | 0.45KB | ▼ 60.95% |