Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲1.03MB] [CPU: ▼5.46ms] Passed 4 tests
Analyzing server-side resources used by DeMomentSomTres Restaurant
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.00 ▲0.54 | 28.01 ▼13.20 |
Dashboard /wp-admin | 4.50 ▲1.20 | 51.14 ▲1.65 |
Posts /wp-admin/edit.php | 4.55 ▲1.20 | 49.22 ▲0.61 |
Add New Post /wp-admin/post-new.php | 7.10 ▲1.21 | 92.14 ▼10.90 |
Media Library /wp-admin/upload.php | 4.42 ▲1.19 | 50.28 ▲18.35 |
Add New /wp-admin/post-new.php?post_type=dish-list | 4.58 | 58.81 |
Install Plugins /wp-admin/themes.php?page=tgmpa-install-plugins | 4.57 | 40.04 |
Menu Types /wp-admin/edit-tags.php?taxonomy=dish-list-type&post_type=dish-list | 4.42 | 39.30 |
All menus /wp-admin/edit.php?post_type=dish-list | 4.47 | 44.40 |
Server storage [IO: ▲10.13MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 333 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-comments |
can_compress_scripts |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-posts |
Browser metrics Passed 4 tests
This is an overview of browser requirements for DeMomentSomTres Restaurant
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,901 ▲144 | 13.26 ▼1.42 | 5.42 ▲3.42 | 41.76 ▼10.38 |
Dashboard /wp-admin | 2,274 ▲89 | 5.98 ▲0.08 | 101.78 ▼17.91 | 42.33 ▼3.03 |
Posts /wp-admin/edit.php | 2,165 ▲76 | 2.19 ▲0.18 | 36.03 ▼1.56 | 34.55 ▲0.10 |
Add New Post /wp-admin/post-new.php | 1,576 ▲34 | 23.40 ▲5.33 | 666.24 ▲25.08 | 62.50 ▲10.48 |
Media Library /wp-admin/upload.php | 1,467 ▲79 | 4.28 ▲0.07 | 99.11 ▲4.71 | 43.74 ▼0.50 |
Add New /wp-admin/post-new.php?post_type=dish-list | 2,922 | 7.93 | 174.37 | 85.57 |
Install Plugins /wp-admin/themes.php?page=tgmpa-install-plugins | 1,023 | 2.07 | 27.76 | 31.30 |
Menu Types /wp-admin/edit-tags.php?taxonomy=dish-list-type&post_type=dish-list | 1,344 | 2.34 | 29.29 | 33.40 |
All menus /wp-admin/edit.php?post_type=dish-list | 1,183 | 2.01 | 34.30 | 35.58 |
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
It is recommended to fix the following
- The uninstall procedure has failed, leaving 6 options in the database
- widget_theysaidso_widget
- can_compress_scripts
- widget_recent-posts
- db_upgraded
- widget_recent-comments
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-css-parser/tests/quickdump.php
- 140× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Dompdf\\Renderer\\AbstractRenderer' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/src/Renderer/Inline.php:19
- > PHP Fatal error
Uncaught Error: Class 'FontLib\\Table\\Table' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-font-lib/src/FontLib/Table/Type/glyf.php:21
- > PHP Warning
"continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/Cpdf.php on line 467
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-css-parser/tests/Sabberworm/CSS/RuleSet/LenientParsingTest.php:8
- > PHP Fatal error
Uncaught Error: Class 'Dompdf\\FrameDecorator\\AbstractFrameDecorator' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/src/FrameDecorator/TableRowGroup.php:20
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-svg-lib/tests/Svg/StyleTest.php:15
- > PHP Fatal error
Uncaught Error: Class 'FontLib\\Glyph\\Outline' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-font-lib/src/FontLib/Glyph/OutlineSimple.php:17
- > PHP Fatal error
Uncaught Error: Class 'Svg\\Tag\\Group' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-svg-lib/src/Svg/Tag/Anchor.php:11
- > PHP Fatal error
Uncaught Error: Class 'Dompdf\\Positioner\\AbstractPositioner' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/src/Positioner/ListBullet.php:19
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/demomentsomtres-restaurant/lib/dompdf/lib/php-font-lib/tests/FontLib/FontTest.php:7
- > 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 is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
7 plugin tags: woocommerce, menu, restaurant menu, custom post type, restaurant carte...
demomentsomtres-restaurant/demomentsomtres-restaurant.php 92% from 13 tests
This is the main PHP file of "DeMomentSomTres Restaurant" version 202105030000..., providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
- Version: Use only periods and digits for the version number (ex. "1.0.3" instead of "202105030000...")
Code Analysis 97% from 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
Good job! No executable or dangerous file extensions detected42,564 lines of code in 254 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 196 | 8,778 | 16,666 | 40,073 |
Markdown | 6 | 255 | 0 | 909 |
CSS | 31 | 134 | 60 | 650 |
PO File | 2 | 168 | 197 | 416 |
XML | 7 | 3 | 2 | 214 |
JSON | 5 | 0 | 0 | 135 |
JavaScript | 2 | 1 | 0 | 87 |
YAML | 4 | 16 | 3 | 63 |
HTML | 1 | 0 | 0 | 17 |
PHP code 50% from 2 tests
Analyzing cyclomatic complexity and code structure
Please fix the following
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 652)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.42 |
Average class complexity | 35.84 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 765.00 |
Average method complexity | 4.28 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 652.00 |
Code structure | ||
---|---|---|
Namespaces | 33 | |
Interfaces | 5 | |
Traits | 0 | |
Classes | 185 | |
▷ Abstract classes | 12 | 6.49% |
▷ Concrete classes | 173 | 93.51% |
▷ Final classes | 0 | 0.00% |
Methods | 2,081 | |
▷ Static methods | 93 | 4.47% |
▷ Public methods | 1,778 | 85.44% |
▷ Protected methods | 208 | 10.00% |
▷ Private methods | 95 | 4.57% |
Functions | 18 | |
▷ Named functions | 3 | 16.67% |
▷ Anonymous functions | 15 | 83.33% |
Constants | 180 | |
▷ Global constants | 2 | 1.11% |
▷ Class constants | 178 | 98.89% |
▷ Public constants | 178 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
6 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
mce_plugins/icon-glutenfree.png | 7.11KB | 4.44KB | ▼ 37.59% |
mce_plugins/icon-template.png | 11.43KB | 3.91KB | ▼ 65.78% |
mce_plugins/icon-veg.png | 7.56KB | 2.80KB | ▼ 63.03% |
mce_plugins/icon-eco.png | 6.97KB | 1.61KB | ▼ 76.86% |
mce_plugins/icon-price.png | 6.80KB | 2.22KB | ▼ 67.28% |