Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.26MB] [CPU: ▼1.37ms] Passed 4 tests
Analyzing server-side resources used by Simple CPT
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.71 ▲0.25 | 42.43 ▲3.22 |
Dashboard /wp-admin | 3.55 ▲0.25 | 49.30 ▲2.40 |
Posts /wp-admin/edit.php | 3.67 ▲0.31 | 47.20 ▲0.74 |
Add New Post /wp-admin/post-new.php | 6.16 ▲0.27 | 85.51 ▼9.48 |
Media Library /wp-admin/upload.php | 3.48 ▲0.25 | 38.52 ▲0.88 |
Overview /wp-admin/admin.php?page=simple-cpt | 3.50 | 35.50 |
Post Types /wp-admin/edit.php?post_type=simple_cpt | 3.52 | 41.23 |
Taxonomies /wp-admin/edit.php?post_type=simple_tax | 3.52 | 37.28 |
Server storage [IO: ▲0.14MB] [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: 25 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
db_upgraded |
can_compress_scripts |
theysaidso_admin_options |
widget_recent-posts |
widget_recent-comments |
Browser metrics Passed 4 tests
Simple CPT: an overview of browser usage
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,940 ▲179 | 13.52 ▼0.84 | 8.30 ▲6.70 | 44.33 ▲3.02 |
Dashboard /wp-admin | 2,229 ▲58 | 5.60 ▲0.02 | 95.02 ▲7.02 | 45.04 ▲7.10 |
Posts /wp-admin/edit.php | 2,137 ▲37 | 1.98 ▼0.02 | 37.08 ▲1.05 | 32.46 ▼3.70 |
Add New Post /wp-admin/post-new.php | 1,560 ▲32 | 23.02 ▼0.14 | 655.85 ▼17.53 | 65.94 ▲11.27 |
Media Library /wp-admin/upload.php | 1,440 ▲40 | 4.18 ▼0.03 | 95.11 ▼9.41 | 41.74 ▼2.68 |
Overview /wp-admin/admin.php?page=simple-cpt | 992 | 1.99 | 23.67 | 41.94 |
Post Types /wp-admin/edit.php?post_type=simple_cpt | 1,179 | 1.95 | 31.81 | 45.19 |
Taxonomies /wp-admin/edit.php?post_type=simple_tax | 1,164 | 1.96 | 35.28 | 32.03 |
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
It is recommended to fix the following
- The uninstall procedure has failed, leaving 6 options in the database
- widget_recent-posts
- theysaidso_admin_options
- db_upgraded
- widget_theysaidso_widget
- can_compress_scripts
- widget_recent-comments
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)
Everything seems fine, however this is by no means an exhaustive test
SRP 0% 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 fix the following
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/simple-cpt/public/partials/simple-cpt-public-display.php
- 4× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/simple-cpt/admin/partials/simple-cpt-metabox-tax.php:15
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/simple-cpt/admin/partials/simple-cpt-metabox-cpt.php:15
- > PHP Fatal error
Uncaught Error: Class 'WP_Query' not found in wp-content/plugins/simple-cpt/admin/partials/simple-cpt-admin-display.php:19
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/simple-cpt/admin/partials/simple-cpt-admin-footer.php:18
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: custom post type, cpt, simple cpt, taxonomies
simple-cpt/simple-cpt.php Passed 13 tests
This is the main PHP file of "Simple CPT" version 1.0.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
114 characters long description:
Simple CPT provides an easy to use interface for registering and managing Custom Post Types and Custom Taxonomies.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin1,427 lines of code in 19 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 15 | 259 | 662 | 1,276 |
CSS | 2 | 0 | 4 | 132 |
JavaScript | 2 | 8 | 27 | 19 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.37 |
Average class complexity | 29.71 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 198.00 |
Average method complexity | 5.57 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 82.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 | 44 | |
▷ Static methods | 2 | 4.55% |
▷ Public methods | 39 | 88.64% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 11.36% |
Functions | 3 | |
▷ Named functions | 3 | 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
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin