Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
- The plugin did not install without errors
- > Deprecated in wp-content/plugins/code-school-badges/wpcodeschool-badges.php+85
Methods with the same name as their class will not be constructors in a future version of PHP; Wpcodeschool_Badges_Widget has a deprecated constructor
Server metrics [RAM: ▲0.01MB] [CPU: ▼146.11ms] Passed 4 tests
Analyzing server-side resources used by Code School Badges
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.86 ▲0.02 | 25.72 ▲0.16 |
Dashboard /wp-admin | 3.07 ▲0.01 | 34.61 ▼5.55 |
Posts /wp-admin/edit.php | 3.13 ▲0.02 | 32.00 ▼1.52 |
Add New Post /wp-admin/post-new.php | 5.44 ▼0.00 | 70.82 ▼577.53 |
Media Library /wp-admin/upload.php | 3.02 ▲0.01 | 25.33 ▲1.01 |
Code School Badges /wp-admin/options-general.php?page=wpcodeschool-badges | 3.06 | 23.38 |
Server storage [IO: ▲1.49MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 1 new option
New WordPress options |
---|
widget_wpcodeschool_badges_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Code School Badges
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,853 ▲252 | 16.00 ▲0.20 | 12.24 ▲7.26 | 75.34 ▼1.82 |
Dashboard /wp-admin | 2,952 ▲56 | 6.10 ▼0.11 | 112.50 ▼14.86 | 164.02 ▼7.32 |
Posts /wp-admin/edit.php | 2,738 ▼2 | 3.25 ▼0.11 | 64.56 ▲2.90 | 132.64 ▼2.11 |
Add New Post /wp-admin/post-new.php | 3,818 ▲3 | 19.12 ▼0.23 | 415.02 ▼10.24 | 163.12 ▼5.91 |
Media Library /wp-admin/upload.php | 1,807 ▲52 | 5.55 ▲0.01 | 138.36 ▼1.80 | 183.54 ▼2.34 |
Code School Badges /wp-admin/options-general.php?page=wpcodeschool-badges | 1,240 | 2.41 | 56.01 | 111.30 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- This plugin did not uninstall successfully, leaving 1 option in the database
- widget_wpcodeschool_badges_widget
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test
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
Almost there! Just fix the following items
- 2× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/code-school-badges/inc/front-end.php
- > /wp-content/plugins/code-school-badges/inc/front-end-shortcode.php
- 26× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Notice
Undefined variable: before_widget in wp-content/plugins/code-school-badges/inc/front-end.php on line 2
- > PHP Notice
Undefined variable: before_title in wp-content/plugins/code-school-badges/inc/front-end-shortcode.php on line 3
- > PHP Notice
Undefined variable: after_title in wp-content/plugins/code-school-badges/inc/front-end.php on line 3
- > PHP Notice
Undefined variable: after_widget in wp-content/plugins/code-school-badges/inc/front-end-shortcode.php on line 18
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/code-school-badges/wpcodeschool-badges.php:37
- > PHP Notice
Undefined variable: wpcodeschool_profile in wp-content/plugins/code-school-badges/inc/front-end.php on line 5
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/code-school-badges/inc/options-page-wrapper.php:38
- > PHP Notice
Undefined variable: before_title in wp-content/plugins/code-school-badges/inc/front-end.php on line 3
- > PHP Warning
count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/code-school-badges/inc/front-end.php on line 6
- > PHP Notice
Undefined variable: after_title in wp-content/plugins/code-school-badges/inc/front-end-shortcode.php on line 3
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side
Optimizations
Plugin configuration 96% from 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
8 plugin tags: code school, profile, shortcode, badges, education...
code-school-badges/wpcodeschool-badges.php 92% from 13 tests
This is the main PHP file of "Code School Badges" version 1.0.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("code-school-badges.php" instead of "wpcodeschool-badges.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin422 lines of code in 7 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 5 | 111 | 67 | 335 |
CSS | 1 | 5 | 14 | 81 |
JavaScript | 1 | 5 | 8 | 6 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.22 |
Average class complexity | 3.00 |
▷ Minimum class complexity | 3.00 |
▷ Maximum class complexity | 3.00 |
Average method complexity | 1.50 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 10 | |
▷ Named functions | 10 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 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
6 PNG files occupy 1.46MB with 1.09MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/screenshot-2.png | 142.99KB | 36.20KB | ▼ 74.69% |
assets/screenshot-6.png | 419.94KB | 100.82KB | ▼ 75.99% |
assets/screenshot-3.png | 356.96KB | 86.31KB | ▼ 75.82% |
assets/screenshot-1.png | 142.20KB | 36.02KB | ▼ 74.67% |
assets/screenshot-4.png | 207.74KB | 56.91KB | ▼ 72.60% |