Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▼5.19ms] Passed 4 tests
Analyzing server-side resources used by LTK Google Analytics
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.00 | 39.38 ▼6.29 |
Dashboard /wp-admin | 3.33 ▼0.02 | 48.60 ▼15.87 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 53.04 ▲5.55 |
Add New Post /wp-admin/post-new.php | 5.91 ▲0.02 | 95.89 ▼2.50 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 41.21 ▲3.91 |
Google Analytics /wp-admin/options-general.php?page=ltk-google-analytics | 3.24 | 31.83 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
widget_recent-comments |
widget_recent-posts |
db_upgraded |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
This is an overview of browser requirements for LTK Google Analytics
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,819 ▲58 | 13.24 ▼1.30 | 1.59 ▼0.14 | 40.54 ▼5.90 |
Dashboard /wp-admin | 2,228 ▲25 | 4.85 ▼1.06 | 99.28 ▼4.40 | 39.82 ▼1.61 |
Posts /wp-admin/edit.php | 2,104 ▲1 | 2.03 ▼0.00 | 42.50 ▲4.07 | 35.83 ▼0.88 |
Add New Post /wp-admin/post-new.php | 1,543 ▲17 | 18.25 ▲0.52 | 613.92 ▼74.64 | 52.05 ▼5.20 |
Media Library /wp-admin/upload.php | 1,404 ▲4 | 4.35 ▲0.02 | 97.35 ▼7.56 | 43.01 ▼8.48 |
Google Analytics /wp-admin/options-general.php?page=ltk-google-analytics | 816 | 2.03 | 26.49 | 29.70 |
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
These items require your attention
- Zombie WordPress options were found after uninstall: 6 options
- theysaidso_admin_options
- db_upgraded
- widget_theysaidso_widget
- widget_recent-comments
- can_compress_scripts
- widget_recent-posts
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected
SRP 0% 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
Almost there! Just fix the following items
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/ltk-google-analytics/templates/analyticsjs.php
- 8× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
require_once(): Failed opening required 'wp-content/plugins/ltk-google-analytics/vendor/composer/autoload_real.php' (include_path='.:/usr/share/php') in wp-content/plugins/ltk-google-analytics/vendor/autoload.php on line 5
- > PHP Warning
require_once(wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/tests/init.php on line 3
- > PHP Fatal error
require_once(): Failed opening required 'wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/tests/init.php on line 3
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/ltk-google-analytics/templates/admin/ltk-google-analytics.php:2
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/tests/unit/String/TransliteratorTest.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/ltk-google-analytics/ltk-google-analytics.php:20
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/ltk-google-analytics/vendor/limitrek/lib-php/tests/unit/String/UnicodeTest.php:5
- > PHP Warning
require_once(wp-content/plugins/ltk-google-analytics/vendor/composer/autoload_real.php): failed to open stream: No such file or directory in wp-content/plugins/ltk-google-analytics/vendor/autoload.php on line 5
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration Passed 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
3 plugin tags: statistics, google, analytics
ltk-google-analytics/ltk-google-analytics.php Passed 13 tests
The main PHP script in "LTK Google Analytics" version 1.0.0 is automatically included on every request by WordPress
79 characters long description:
Add the Google Analytics code to your website to get stats and track variables.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin748 lines of code in 17 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 14 | 254 | 247 | 710 |
JSON | 1 | 0 | 0 | 21 |
Markdown | 1 | 5 | 0 | 11 |
XML | 1 | 0 | 0 | 6 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 9.14 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 18.00 |
Average method complexity | 2.58 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 12.00 |
Code structure | ||
---|---|---|
Namespaces | 3 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 34 | |
▷ Static methods | 3 | 8.82% |
▷ Public methods | 27 | 79.41% |
▷ Protected methods | 6 | 17.65% |
▷ Private methods | 1 | 2.94% |
Functions | 6 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 6 | 100.00% |
Constants | 4 | |
▷ Global constants | 4 | 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
PNG images were not found in this plugin