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
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.07MB] [CPU: ▼3.99ms] Passed 4 tests
Analyzing server-side resources used by GAPlugin - DarkMode
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.53 ▲0.07 | 44.34 ▲3.47 |
Dashboard /wp-admin | 3.38 ▲0.07 | 50.24 ▼2.41 |
Posts /wp-admin/edit.php | 3.49 ▲0.13 | 49.08 ▼0.49 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.07 | 93.22 ▼16.51 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 43.62 ▲10.04 |
Darkmode /wp-admin/admin.php?page=gap-admin-page-darkmode | 3.26 | 32.21 |
GAPlugin /wp-admin/admin.php?page=gap-admin-page | 3.26 | 34.35 |
Server storage [IO: ▲0.07MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for GAPlugin - DarkMode
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,824 ▲78 | 14.27 ▼0.02 | 2.41 ▲0.88 | 42.65 ▲1.77 |
Dashboard /wp-admin | 2,226 ▲52 | 5.84 ▲0.30 | 83.66 ▼5.52 | 73.10 ▲27.46 |
Posts /wp-admin/edit.php | 2,134 ▲34 | 1.99 ▼0.02 | 37.68 ▲1.63 | 31.98 ▼2.26 |
Add New Post /wp-admin/post-new.php | 1,708 ▲168 | 21.83 ▲3.54 | 740.59 ▲75.58 | 60.67 ▼18.68 |
Media Library /wp-admin/upload.php | 1,434 ▲34 | 4.15 ▼0.05 | 100.85 ▼5.10 | 76.89 ▲33.84 |
Darkmode /wp-admin/admin.php?page=gap-admin-page-darkmode | 831 | 2.03 | 26.37 | 29.32 |
GAPlugin /wp-admin/admin.php?page=gap-admin-page | 820 | 1.99 | 29.11 | 29.07 |
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
It is recommended to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_theysaidso_widget
- widget_recent-comments
- db_upgraded
- widget_recent-posts
- can_compress_scripts
- theysaidso_admin_options
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 | 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 items
- 1× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/darkmode-ga/gaplugin-darkmode-plugin.php
- 1× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Class 'GAPlugin\\AdminPage' not found in wp-content/plugins/darkmode-ga/includes/DarkMode.php:10
- > 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 errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: dark, darkmode, light, navigation, colors
darkmode-ga/gaplugin-darkmode-plugin.php 85% from 13 tests
The entry point to "GAPlugin - DarkMode" version 0.01.00.00 is a PHP file that has certain tags in its header comment area
The following require your attention:
- Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
- Main file name: It is recommended to name the main PHP file as the plugin slug ("darkmode-ga.php" instead of "gaplugin-darkmode-plugin.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin404 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 21 | 97 | 222 |
CSS | 3 | 3 | 19 | 83 |
PO File | 1 | 17 | 23 | 43 |
Markdown | 1 | 6 | 0 | 31 |
JavaScript | 1 | 1 | 0 | 19 |
SVG | 1 | 0 | 0 | 6 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.19 |
Average class complexity | 4.00 |
▷ Minimum class complexity | 3.00 |
▷ Maximum class complexity | 5.00 |
Average method complexity | 1.25 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 2.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 24 | |
▷ Static methods | 24 | 100.00% |
▷ Public methods | 24 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 2 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 2 | 100.00% |
Constants | 2 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 2 | 100.00% |
▷ Public constants | 2 | 100.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