Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲5.55MB] [CPU: ▲17.55ms] 75% from 4 tests
Server-side resources used by Printable PDF Newspaper
The following require your attention
- Extra RAM: The extra memory usage should kept under 5MB (currently 5.55MB on /wp-admin/upload.php)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 37.16 ▼0.45 |
Dashboard /wp-admin | 11.26 ▲7.96 | 74.54 ▲28.26 |
Posts /wp-admin/edit.php | 11.27 ▲7.91 | 70.77 ▲21.68 |
Add New Post /wp-admin/post-new.php | 12.19 ▲6.31 | 107.75 ▲20.72 |
Media Library /wp-admin/upload.php | 11.27 ▲8.04 | 75.39 ▲42.88 |
Server storage [IO: ▲31.94MB] [DB: ▲0.00MB] 67% from 3 tests
Filesystem and database footprint
It is recommended to fix the following issues
- Try to limit filesystem usage to 25MB (currently using 31.94MB)
Filesystem: 323 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-comments |
can_compress_scripts |
db_upgraded |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
A check of browser resources used by Printable PDF Newspaper
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,801 ▲15 | 14.17 ▼0.34 | 1.55 ▼0.29 | 37.41 ▼7.52 |
Dashboard /wp-admin | 2,204 ▲27 | 5.51 ▼0.04 | 83.03 ▼5.05 | 36.81 ▼3.59 |
Posts /wp-admin/edit.php | 2,115 ▲18 | 2.03 ▲0.09 | 33.80 ▼3.07 | 31.70 ▼3.04 |
Add New Post /wp-admin/post-new.php | 1,536 ▲10 | 23.44 ▲0.53 | 646.34 ▼38.28 | 54.49 ▲2.50 |
Media Library /wp-admin/upload.php | 1,415 ▲21 | 4.21 ▲0.04 | 95.24 ▼2.51 | 41.50 ▼1.96 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
- Zombie WordPress options detected upon uninstall: 6 options
- can_compress_scripts
- widget_recent-posts
- theysaidso_admin_options
- db_upgraded
- widget_recent-comments
- widget_theysaidso_widget
Smoke tests 50% 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)
The smoke test was a success, however most plugin functionality was not tested
SRP 0% 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
The following issues need your attention
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/printable-pdf-newspaper/lib/tcpdf/tools/tcpdf_addfont.php
- 1× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Class 'TCPDF' not found in wp-content/plugins/printable-pdf-newspaper/classes/class-admin-newspaper-tcpdf.php:11
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: newsletter, print, newspaper, journalism, news...
printable-pdf-newspaper/printable-pdf-newspaper.php Passed 13 tests
"Printable PDF Newspaper" version 1.1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
45 characters long description:
Generate a Printable PDF Newspaper from Posts
Code Analysis 95% 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
Everything looks great! No dangerous files found in this plugin62,926 lines of code in 179 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 106 | 1,581 | 11,962 | 47,885 |
JavaScript | 66 | 3,767 | 1,086 | 14,433 |
CSS | 4 | 72 | 5 | 497 |
Markdown | 1 | 21 | 0 | 63 |
JSON | 1 | 0 | 0 | 47 |
YAML | 1 | 0 | 0 | 1 |
PHP code 0% from 2 tests
A short review of cyclomatic complexity and code structure
Please tend to the following items
- Cyclomatic complexity of classes should be reduced to less than 1000 (currently 4,379)
- Method cyclomatic complexity should be reduced to less than 100 (currently 502)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.42 |
Average class complexity | 325.20 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 4,379.00 |
Average method complexity | 9.89 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 502.00 |
Code structure | ||
---|---|---|
Namespaces | 2 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 20 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 20 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 730 | |
▷ Static methods | 110 | 15.07% |
▷ Public methods | 446 | 61.10% |
▷ Protected methods | 278 | 38.08% |
▷ Private methods | 6 | 0.82% |
Functions | 4 | |
▷ Named functions | 3 | 75.00% |
▷ Anonymous functions | 1 | 25.00% |
Constants | 106 | |
▷ Global constants | 106 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 1.76MB with 1.26MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 1,522.31KB | 434.64KB | ▼ 71.45% |
screenshot-2.png | 279.52KB | 79.78KB | ▼ 71.46% |