Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.25MB] [CPU: ▼6.10ms] Passed 4 tests
This is a short check of server-side resources used by Export2Word
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.66 ▲0.20 | 42.99 ▲6.06 |
Dashboard /wp-admin | 3.59 ▲0.24 | 50.33 ▼17.58 |
Posts /wp-admin/edit.php | 3.64 ▲0.29 | 54.84 ▼1.23 |
Add New Post /wp-admin/post-new.php | 6.20 ▲0.31 | 93.95 ▼11.63 |
Media Library /wp-admin/upload.php | 3.51 ▲0.28 | 42.04 ▲6.07 |
Export2Word /wp-admin/tools.php?page=export2word | 3.50 | 38.11 |
Server storage [IO: ▲9.26MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 1,297 new files
Database: no new tables, 8 new options
New WordPress options |
---|
widget_theysaidso_widget |
e2w_version |
e2w_db_version |
can_compress_scripts |
db_upgraded |
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Export2Word: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,835 ▲74 | 13.36 ▼0.85 | 4.39 ▲2.32 | 41.02 ▼2.71 |
Dashboard /wp-admin | 2,242 ▲39 | 4.91 ▼0.97 | 111.34 ▼5.14 | 42.81 ▼3.50 |
Posts /wp-admin/edit.php | 2,118 ▲18 | 2.08 ▲0.02 | 43.34 ▲6.97 | 34.76 ▲0.31 |
Add New Post /wp-admin/post-new.php | 1,377 ▼155 | 16.68 ▼6.51 | 571.70 ▼105.70 | 48.29 ▼9.15 |
Media Library /wp-admin/upload.php | 1,421 ▲18 | 4.24 ▲0.04 | 102.14 ▲2.27 | 45.44 ▼3.49 |
Export2Word /wp-admin/tools.php?page=export2word | 1,013 | 2.23 | 27.27 | 27.40 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
- This plugin did not uninstall successfully, leaving 8 options in the database
- e2w_version
- widget_recent-comments
- e2w_db_version
- widget_recent-posts
- db_upgraded
- can_compress_scripts
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected
SRP 0% 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× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/export2word/inc/fun/autoload/e2w_export_on_save_post.php
- 662× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/export2word/vendor/phpoffice/phpword/tests/PhpWord/Style/TabTest.php:25
- > PHP Fatal error
Uncaught Exception: Could not find file '/autoload.php'. It is generated by Composer. Use 'install --prefer-source' or 'update --prefer-source' Composer commands to move forward. in wp-content/plugins/export2word/vendor/phpoffice/phpword/bootstrap.php:22
- > PHP Fatal error
Uncaught Error: Interface 'Zend\\Stdlib\\Hydrator\\Filter\\FilterInterface' not found in wp-content/plugins/export2word/vendor/zendframework/zend-stdlib/src/Hydrator/Filter/OptionalParametersFilter.php:19
- > PHP Warning
require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/export2word/inc/fun/autoload/menu_page/class-e2w_list_table_documents.php on line 4
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/export2word/vendor/phpoffice/phpword/tests/PhpWord/Element/TextTest.php:28
- > PHP Fatal error
Uncaught Error: Class 'PhpOffice\\PhpWord\\Writer\\HTML\\Style\\AbstractStyle' not found in wp-content/plugins/export2word/vendor/phpoffice/phpword/src/PhpWord/Writer/HTML/Style/Font.php:27
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/export2word/vendor/composer/installers/src/Composer/Installers/HuradInstaller.php:4
- > PHP Fatal error
Uncaught Error: Class 'Zend\\Validator\\AbstractValidator' not found in wp-content/plugins/export2word/vendor/zendframework/zend-validator/src/File/Exists.php:18
- > PHP Fatal error
Uncaught Error: Class 'PhpOffice\\PhpWord\\Writer\\Word2007\\Style\\AbstractStyle' not found in wp-content/plugins/export2word/vendor/phpoffice/phpword/src/PhpWord/Writer/Word2007/Style/Cell.php:27
- > PHP Fatal error
Uncaught Exception: Could not find file '/autoload.php'. It is generated by Composer. Use 'install --prefer-source' or 'update --prefer-source' Composer commands to move forward. in wp-content/plugins/export2word/vendor/phpoffice/phpword/bootstrap.php:22
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: phpword, docx, export, word
export2word/export2word.php Passed 13 tests
"Export2Word" version 0.0.6's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
35 characters long description:
Export a website as a docx document
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin121,601 lines of code in 1,078 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 808 | 12,817 | 40,052 | 59,486 |
PO File | 120 | 13,787 | 17,890 | 31,582 |
JavaScript | 38 | 2,156 | 2,988 | 18,404 |
CSS | 22 | 1,200 | 1,198 | 5,243 |
Markdown | 20 | 660 | 0 | 2,082 |
Sass | 15 | 291 | 25 | 1,330 |
JSON | 14 | 0 | 0 | 1,091 |
HTML | 13 | 69 | 5 | 760 |
reStructuredText | 13 | 348 | 319 | 755 |
SVG | 2 | 0 | 1 | 463 |
XML | 8 | 18 | 16 | 214 |
make | 1 | 24 | 5 | 124 |
Python | 1 | 79 | 175 | 36 |
XSLT | 2 | 5 | 0 | 30 |
YAML | 1 | 0 | 0 | 1 |
PHP code 50% from 2 tests
An overview of cyclomatic complexity and code structure
Please tend to the following items
- Please reduce cyclomatic complexity of methods to less than 100 (currently 116)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.28 |
Average class complexity | 8.69 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 553.00 |
Average method complexity | 2.70 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 116.00 |
Code structure | ||
---|---|---|
Namespaces | 63 | |
Interfaces | 37 | |
Traits | 5 | |
Classes | 716 | |
▷ Abstract classes | 44 | 6.15% |
▷ Concrete classes | 672 | 93.85% |
▷ Final classes | 14 | 2.08% |
Methods | 3,515 | |
▷ Static methods | 312 | 8.88% |
▷ Public methods | 2,993 | 85.15% |
▷ Protected methods | 305 | 8.68% |
▷ Private methods | 217 | 6.17% |
Functions | 85 | |
▷ Named functions | 62 | 72.94% |
▷ Anonymous functions | 23 | 27.06% |
Constants | 679 | |
▷ Global constants | 139 | 20.47% |
▷ Class constants | 540 | 79.53% |
▷ Public constants | 540 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
24 compressed PNG files occupy 0.13MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
vendor/phpoffice/phpword/src/PhpWord/resources/ppt.png | 1.84KB | 1.79KB | ▼ 2.97% |
vendor/phpoffice/phpword/src/PhpWord/resources/xls.png | 1.88KB | 1.82KB | ▼ 3.27% |
images/32px.png | 3.05KB | 2.88KB | ▼ 5.58% |
vendor/webdevstudios/cmb2/images/ui-bg_glass_55_fbf9ee_1x400.png | 0.12KB | 0.14KB | 0.00% |
vendor/webdevstudios/cmb2/images/ui-icons_454545_256x240.png | 4.27KB | 4.11KB | ▼ 3.78% |