Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully
Server metrics [RAM: ▲0.18MB] [CPU: ▼5.32ms] Passed 4 tests
An overview of server-side resources used by SuperCPT
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.64 ▲0.18 | 43.03 ▲1.96 |
Dashboard /wp-admin | 3.49 ▲0.18 | 46.88 ▼0.73 |
Posts /wp-admin/edit.php | 3.60 ▲0.24 | 48.52 ▼6.98 |
Add New Post /wp-admin/post-new.php | 6.09 ▲0.20 | 82.47 ▼15.53 |
Media Library /wp-admin/upload.php | 3.41 ▲0.18 | 38.42 ▲3.90 |
SuperCPT /wp-admin/tools.php?page=super_cpt | 3.71 | 32.71 |
Server storage [IO: ▲0.49MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_recent-posts |
widget_recent-comments |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
This is an overview of browser requirements for SuperCPT
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,806 ▲71 | 13.17 ▼1.09 | 1.70 ▼0.12 | 44.32 ▼5.99 |
Dashboard /wp-admin | 2,212 ▲24 | 5.91 ▲1.03 | 102.42 ▼7.79 | 40.70 ▼2.60 |
Posts /wp-admin/edit.php | 2,095 ▲3 | 2.03 ▲0.03 | 38.05 ▼5.65 | 34.78 ▼1.72 |
Add New Post /wp-admin/post-new.php | 1,519 ▼9 | 23.19 ▲5.25 | 651.69 ▲13.29 | 51.39 ▼6.55 |
Media Library /wp-admin/upload.php | 1,391 ▼0 | 4.24 ▲0.02 | 108.18 ▲7.22 | 42.87 ▼3.32 |
SuperCPT /wp-admin/tools.php?page=super_cpt | 3,053 | 2.01 | 26.87 | 76.42 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_recent-posts
- can_compress_scripts
- theysaidso_admin_options
- widget_theysaidso_widget
- widget_recent-comments
- db_upgraded
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
- 4× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/super-cpt/super-cpt.php:28
- > PHP Fatal error
Uncaught Error: Class 'Super_Custom_Post_Meta' not found in wp-content/plugins/super-cpt/includes/class-super-custom-post-type.php:9
- > PHP Warning
Use of undefined constant SCPT_PLUGIN_URL - assumed 'SCPT_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/super-cpt/includes/class-scpt-font-awesome.php on line 34
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-cpt/includes/class-scpt-font-awesome.php:37
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
8 plugin tags: meta, custom-taxonomy, custom-field, custom-taxonomies, cms...
super-cpt/super-cpt.php Passed 13 tests
This is the main PHP file of "SuperCPT" version 0.2.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
87 characters long description:
Insanely easy and attractive custom post types, custom post meta, and custom taxonomies
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
Success! There were no dangerous files found in this plugin2,180 lines of code in 11 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 8 | 271 | 664 | 1,675 |
SVG | 1 | 0 | 0 | 399 |
CSS | 1 | 7 | 3 | 75 |
JavaScript | 1 | 3 | 0 | 31 |
PHP code 50% from 2 tests
This plugin's cyclomatic complexity and code structure detailed below
These items need your attention
- Cyclomatic complexity of methods should be reduced to less than 100 (currently 377)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.83 |
Average class complexity | 79.14 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 389.00 |
Average method complexity | 9.04 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 377.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 68 | |
▷ Static methods | 4 | 5.88% |
▷ Public methods | 64 | 94.12% |
▷ Protected methods | 3 | 4.41% |
▷ Private methods | 1 | 1.47% |
Functions | 8 | |
▷ Named functions | 8 | 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 Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin