Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully
Server metrics [RAM: ▲0.02MB] [CPU: ▼4.44ms] Passed 4 tests
Server-side resources used by Only One Category
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 33.92 ▼9.53 |
Dashboard /wp-admin | 3.31 ▲0.01 | 45.55 ▲0.74 |
Posts /wp-admin/edit.php | 3.41 ▲0.06 | 48.34 ▼2.44 |
Add New Post /wp-admin/post-new.php | 6.05 ▲0.17 | 93.09 ▼2.01 |
Media Library /wp-admin/upload.php | 3.23 ▲0.01 | 32.11 ▼3.78 |
Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for Only One Category
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲65 | 13.22 ▼1.53 | 1.79 ▼0.05 | 40.18 ▼5.72 |
Dashboard /wp-admin | 2,206 ▲18 | 5.91 ▲0.99 | 108.29 ▼9.90 | 42.69 ▼1.24 |
Posts /wp-admin/edit.php | 2,094 ▲5 | 2.02 ▲0.04 | 39.93 ▲1.97 | 35.18 ▼1.12 |
Add New Post /wp-admin/post-new.php | 1,514 ▼19 | 23.39 ▼0.06 | 592.34 ▼86.21 | 51.17 ▲5.88 |
Media Library /wp-admin/upload.php | 1,382 ▼9 | 4.21 ▲0.02 | 94.20 ▼4.57 | 41.56 ▼4.08 |
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
You still need to fix the following
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_theysaidso_widget
- widget_recent-comments
- theysaidso_admin_options
- widget_recent-posts
- db_upgraded
- can_compress_scripts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested
SRP 50% 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
Almost there! Just fix the following items
- 1× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/only-one-category/main.php:11
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
- Screenshots: These screenshots require images: #1 (How it'll make the Categories section look while editing a post on the current version of WordPress.), #2 (How it looks when you Quick Edit a post with the new UI.)
only-one-category/main.php 92% from 13 tests
Analyzing the main PHP file in "Only One Category" version 1.0.4
You should first fix the following items:
- Main file name: The principal plugin file should be the same as the plugin slug ("only-one-category.php" instead of "main.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected49 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 10 | 10 | 27 |
JavaScript | 1 | 12 | 13 | 22 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.60 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.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
2 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-2.png | 24.74KB | 7.72KB | ▼ 68.81% |
screenshot-1.png | 21.54KB | 5.77KB | ▼ 73.20% |