Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully
Server metrics [RAM: ▲0.23MB] [CPU: ▼4.23ms] Passed 4 tests
A check of server-side resources used by Copy to Clipboard for WordPress
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.75 ▲0.29 | 37.67 ▼1.81 |
Dashboard /wp-admin | 3.57 ▲0.22 | 50.41 ▼12.76 |
Posts /wp-admin/edit.php | 3.62 ▲0.26 | 49.84 ▲4.33 |
Add New Post /wp-admin/post-new.php | 6.11 ▲0.23 | 87.26 ▼6.68 |
Media Library /wp-admin/upload.php | 3.43 ▲0.20 | 38.68 ▲4.37 |
Help /wp-admin/edit.php?post_type=copy_to_clipboard&page=help | 6.56 | 44.87 |
Add New /wp-admin/post-new.php?post_type=copy_to_clipboard | 3.87 | 57.86 |
All Items /wp-admin/edit.php?post_type=copy_to_clipboard | 3.86 | 44.70 |
Server storage [IO: ▲2.15MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 210 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_recent-posts |
widget_recent-comments |
widget_theysaidso_widget |
db_upgraded |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Copy to Clipboard for WordPress: an overview of browser usage
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,928 ▲156 | 13.35 ▼0.97 | 8.33 ▲6.28 | 39.20 ▼3.33 |
Dashboard /wp-admin | 2,247 ▲70 | 5.59 ▼0.06 | 84.28 ▼17.14 | 39.19 ▼4.10 |
Posts /wp-admin/edit.php | 2,152 ▲52 | 2.00 ▲0.03 | 41.60 ▲3.65 | 35.06 ▲1.43 |
Add New Post /wp-admin/post-new.php | 1,556 ▲18 | 23.34 ▲0.27 | 676.74 ▼35.47 | 51.24 ▼9.90 |
Media Library /wp-admin/upload.php | 1,455 ▲52 | 4.25 ▲0.05 | 95.76 ▼4.76 | 40.66 ▼6.40 |
Help /wp-admin/edit.php?post_type=copy_to_clipboard&page=help | 1,077 | 3.70 | 47.59 | 34.49 |
Add New /wp-admin/post-new.php?post_type=copy_to_clipboard | 8,977 | 5.23 | 479.89 | 56.54 |
All Items /wp-admin/edit.php?post_type=copy_to_clipboard | 1,342 | 3.95 | 48.93 | 26.74 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- can_compress_scripts
- widget_recent-posts
- db_upgraded
- theysaidso_admin_options
- widget_recent-comments
- widget_theysaidso_widget
Smoke tests 50% 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 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
- 2× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/copy-to-clipboard-for-wp/admin/partials/catcwp-admin-display.php
- > /wp-content/plugins/copy-to-clipboard-for-wp/public/partials/catcwp-public-display.php
- 6× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/copy-to-clipboard-for-wp/includes/class-catcwp-custom-post.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/copy-to-clipboard-for-wp/functions.php:13
- > PHP Warning
require_once(wp-content/plugins/copy-to-clipboard-for-wp/vendor/appsero/client/vendor/tareq1988/wp-php-cs-fixer/loader.php): failed to open stream: No such file or directory in wp-content/plugins/copy-to-clipboard-for-wp/vendor/appsero/client/.php-cs-fixer.dist.php on line 3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/copy-to-clipboard-for-wp/widgets/catcwp-widget.php:9
- > PHP Fatal error
require_once(): Failed opening required 'wp-content/plugins/copy-to-clipboard-for-wp/vendor/appsero/client/vendor/tareq1988/wp-php-cs-fixer/loader.php' (include_path='.:/usr/share/php') in wp-content/plugins/copy-to-clipboard-for-wp/vendor/appsero/client/.php-cs-fixer.dist.php on line 3
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/copy-to-clipboard-for-wp/widgets/catcwp-copy-widget.php:3
- > 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 90% from 29 tests
readme.txt Passed 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
6 plugin tags: clipboard, paste, copy to clipboard, content sharing, copy...
copy-to-clipboard-for-wp/catcwp.php 77% from 13 tests
The main PHP script in "Copy to Clipboard for WordPress" version 1.2.0 is automatically included on every request by WordPress
It is important to fix the following:
- Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
- Description: The description should be shorter than 140 characters (currently 150 characters long)
- Main file name: The principal plugin file should be the same as the plugin slug ("copy-to-clipboard-for-wp.php" instead of "catcwp.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin42,188 lines of code in 175 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 118 | 4,137 | 2,932 | 17,926 |
JavaScript | 7 | 1,325 | 531 | 6,662 |
PO File | 20 | 3,198 | 3,591 | 6,500 |
Sass | 16 | 970 | 3 | 5,674 |
CSS | 6 | 378 | 517 | 4,915 |
Markdown | 1 | 82 | 0 | 255 |
JSON | 3 | 0 | 0 | 127 |
XML | 1 | 6 | 11 | 95 |
YAML | 1 | 6 | 0 | 32 |
SVG | 2 | 0 | 0 | 2 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.56 |
Average class complexity | 23.89 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 151.00 |
Average method complexity | 5.47 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 57.00 |
Code structure | ||
---|---|---|
Namespaces | 3 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 80 | |
▷ Abstract classes | 2 | 2.50% |
▷ Concrete classes | 78 | 97.50% |
▷ Final classes | 0 | 0.00% |
Methods | 411 | |
▷ Static methods | 63 | 15.33% |
▷ Public methods | 367 | 89.29% |
▷ Protected methods | 8 | 1.95% |
▷ Private methods | 36 | 8.76% |
Functions | 36 | |
▷ Named functions | 35 | 97.22% |
▷ Anonymous functions | 1 | 2.78% |
Constants | 6 | |
▷ Global constants | 6 | 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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
libs/codestar-framework/assets/images/checkerboard.png | 2.29KB | 2.54KB | 0.00% |