Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▼294.69ms] Passed 4 tests
A check of server-side resources used by Add Script
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.54 ▲0.02 | 59.09 ▲6.28 |
Dashboard /wp-admin | 3.45 ▲0.05 | 34.85 ▼5.28 |
Posts /wp-admin/edit.php | 3.68 ▲0.04 | 38.99 ▼2.77 |
Add New Post /wp-admin/post-new.php | 6.92 ▼0.05 | 99.61 ▼1,167.80 |
Media Library /wp-admin/upload.php | 3.33 ▲0.04 | 27.25 ▼2.90 |
AddScript /wp-admin/options-general.php?page=addscript-settings | 3.30 | 24.96 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 6 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Checking browser requirements for Add Script
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,786 ▲42 | 15.58 ▼0.05 | 5.89 ▼1.10 | 2.32 ▼0.18 |
Dashboard /wp-admin | 2,880 ▲22 | 6.13 ▼0.05 | 121.75 ▼15.16 | 155.71 ▼5.83 |
Posts /wp-admin/edit.php | 2,662 ▼32 | 3.23 ▼0.01 | 62.70 ▲1.66 | 137.37 ▼3.07 |
Add New Post /wp-admin/post-new.php | 1,714 ▲3 | 20.68 ▼0.90 | 430.95 ▲2.46 | 169.16 ▲2.80 |
Media Library /wp-admin/upload.php | 1,706 ▲8 | 5.45 ▼0.08 | 142.55 ▼3.84 | 188.79 ▼0.27 |
AddScript /wp-admin/options-general.php?page=addscript-settings | 1,038 | 2.36 | 55.01 | 121.30 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The plugin uninstalled successfully, without leaving any zombie files or tables
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% 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
Please take a closer look at the following
- 3× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Class 'Addscript\\Base' not found in wp-content/plugins/addscript/src/Addscript/Admin.php:14
- > PHP Fatal error
Uncaught Error: Class 'Addscript\\Base' not found in wp-content/plugins/addscript/src/Addscript/Frontend.php:14
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/addscript/views/admin/settings.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 Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
1 plugin tags: script
addscript/addscript.php Passed 13 tests
Analyzing the main PHP file in "Add Script" version 1.4
51 characters long description:
Simple plugin to add Google Analytics in the footer
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin188 lines of code in 5 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 5 | 184 | 321 | 188 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.13 |
Average class complexity | 3.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 5.00 |
Average method complexity | 1.30 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 2.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 1 | 33.33% |
▷ Concrete classes | 2 | 66.67% |
▷ Final classes | 0 | 0.00% |
Methods | 20 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 8 | 40.00% |
▷ Protected methods | 9 | 45.00% |
▷ Private methods | 3 | 15.00% |
Functions | 1 | |
▷ Named functions | 1 | 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
All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin