Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.02MB] [CPU: ▼6.56ms] Passed 4 tests
Server-side resources used by Guardian News Headlines
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 43.33 ▼3.02 |
Dashboard /wp-admin | 3.33 ▲0.03 | 49.20 ▲0.18 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 47.47 ▼5.38 |
Add New Post /wp-admin/post-new.php | 5.91 ▲0.02 | 86.20 ▼13.05 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 34.81 ▼4.77 |
Server storage [IO: ▲0.46MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 23 new files
Database: 1 new table, 10 new options
New tables |
---|
wp_guardian_headlines |
New WordPress options |
---|
db_upgraded |
can_compress_scripts |
widget_recent-posts |
theysaidso_admin_options |
guardian_headlines_version |
guardian_headlines_sections |
widget_recent-comments |
guardian_headlines_notified |
widget_guardian_headlines_widget |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Guardian News Headlines
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,807 ▲21 | 14.56 ▲0.30 | 1.74 ▼0.15 | 45.15 ▼3.13 |
Dashboard /wp-admin | 2,200 ▲23 | 5.66 ▼0.01 | 90.24 ▼10.13 | 42.08 ▼5.35 |
Posts /wp-admin/edit.php | 2,099 ▼4 | 1.98 ▼0.02 | 36.15 ▼9.39 | 35.79 ▼2.01 |
Add New Post /wp-admin/post-new.php | 1,528 ▲2 | 23.63 ▲0.64 | 691.06 ▲4.31 | 57.44 ▼7.50 |
Media Library /wp-admin/upload.php | 1,402 ▲2 | 4.23 ▲0.10 | 98.55 ▼18.45 | 44.89 ▼4.37 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
- This plugin does not fully uninstall, leaving 7 options in the database
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
- widget_recent-comments
- can_compress_scripts
- widget_guardian_headlines_widget
- db_upgraded
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)
The smoke test was a success, however most plugin functionality was not tested
SRP 50% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
- 5× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Warning
Use of undefined constant WPINC - assumed 'WPINC' (this will throw an Error in a future version of PHP) in wp-content/plugins/guardian-news-headlines/gu_widget.php on line 26
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/guardian-news-headlines/guardian_headlines.php:30
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATHWPINC/widgets.php' (include_path='.:/usr/share/php') in wp-content/plugins/guardian-news-headlines/gu_widget.php on line 26
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/guardian-news-headlines/gu_widget.php on line 26
- > PHP Warning
require_once(ABSPATHWPINC/widgets.php): failed to open stream: No such file or directory in wp-content/plugins/guardian-news-headlines/gu_widget.php on line 26
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
- Screenshots: These screenshots require images: #1 (The widget settings panel), #2 (Available news categories), #3 (The resulting widget), #4 (Changing to most-viewed), #5 (Different feed results for most-viewed articles), #6 (The widget on a dark background)
guardian-news-headlines/guardian_headlines.php 92% from 13 tests
The main PHP file in "Guardian News Headlines" ver. 0.5.4 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("guardian-news-headlines.php" instead of "guardian_headlines.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected496 lines of code in 7 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 4 | 119 | 178 | 405 |
CSS | 2 | 9 | 0 | 62 |
JSON | 1 | 0 | 0 | 29 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.18 |
Average class complexity | 9.50 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 29.00 |
Average method complexity | 2.42 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 10.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 4 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 4 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 24 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 19 | 79.17% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 20.83% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.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
10 PNG files occupy 0.37MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 53.58KB | 18.77KB | ▼ 64.97% |
img/poweredbyguardianWHITE.png | 1.78KB | 1.04KB | ▼ 41.34% |
screenshot-5.png | 40.55KB | 12.74KB | ▼ 68.59% |
img/poweredbyguardianREV.png | 1.95KB | 1.19KB | ▼ 38.87% |
screenshot-4.png | 53.12KB | 18.73KB | ▼ 64.73% |