Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.96MB] [CPU: ▼287.14ms] Passed 4 tests
Server-side resources used by Adshares
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.04 ▲0.52 | 55.23 ▲3.57 |
Dashboard /wp-admin | 4.53 ▲1.12 | 38.35 ▲4.63 |
Posts /wp-admin/edit.php | 4.78 ▲1.14 | 43.68 ▲6.21 |
Add New Post /wp-admin/post-new.php | 8.02 ▲1.05 | 105.15 ▼1,162.98 |
Media Library /wp-admin/upload.php | 4.53 ▲1.24 | 29.13 ▲6.41 |
Adshares /wp-admin/options-general.php?page=adshares-config | 4.68 | 28.44 |
Server storage [IO: ▲2.12MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 1,089 new files
Database: no new tables, 1 new option
New WordPress options |
---|
adshares_settings |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Adshares
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,792 ▲70 | 15.77 ▲0.15 | 5.65 ▼0.01 | 2.24 ▼0.11 |
Dashboard /wp-admin | 2,901 ▲40 | 6.17 ▼0.04 | 115.83 ▼19.93 | 155.82 ▼1.10 |
Posts /wp-admin/edit.php | 2,695 ▲7 | 3.24 ▼0.00 | 66.07 ▲5.10 | 137.84 ▼1.19 |
Add New Post /wp-admin/post-new.php | 1,667 ▼1 | 16.53 ▼2.48 | 391.32 ▼14.73 | 151.06 ▼4.52 |
Media Library /wp-admin/upload.php | 1,707 ▲9 | 5.50 ▼0.00 | 143.94 ▼5.77 | 187.71 ▲0.28 |
Adshares /wp-admin/options-general.php?page=adshares-config | 1,087 | 2.37 | 53.55 | 124.04 |
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
Please fix the following items
- This plugin does not fully uninstall, leaving 1 option in the database
- adshares_settings
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
- 2 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=adshares-config
- > Deprecated in wp-content/plugins/adshares/vendor/twig/twig/lib/Twig/Node.php+198
Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)`
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 1× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/adshares/adshares.php
- 366× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/adshares/vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php:4
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/adshares/vendor/twig/twig/test/Twig/Tests/Loader/ArrayTest.php:12
- > PHP Fatal error
Uncaught Error: Class 'Twig_Node_Expression_Binary' not found in wp-content/plugins/adshares/vendor/twig/twig/lib/Twig/Node/Expression/Binary/Or.php:12
- > PHP Fatal error
Uncaught Error: Class 'Twig_Test_NodeTestCase' not found in wp-content/plugins/adshares/vendor/twig/twig/test/Twig/Tests/Node/Expression/Binary/MulTest.php:12
- > PHP Fatal error
Uncaught Error: Interface 'Twig_RuntimeLoaderInterface' not found in wp-content/plugins/adshares/vendor/twig/twig/lib/Twig/ContainerRuntimeLoader.php:22
- > PHP Fatal error
Uncaught Error: Class 'Twig_Environment' not found in wp-content/plugins/adshares/vendor/twig/twig/test/Twig/Tests/Node/Expression/PHP53/FilterInclude.php:3
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/adshares/vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php:4
- > PHP Fatal error
Uncaught Error: Class 'Twig_Node_Expression_Binary' not found in wp-content/plugins/adshares/vendor/twig/twig/lib/Twig/Node/Expression/Binary/Greater.php:11
- > PHP Fatal error
Uncaught Error: Class 'Twig_TokenParser' not found in wp-content/plugins/adshares/vendor/twig/twig/lib/Twig/TokenParser/Import.php:21
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/adshares/vendor/composer/installers/src/Composer/Installers/ReIndexInstaller.php:4
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
9 plugin tags: ads, ad manager, publisher, ad inserter, ad...
adshares/adshares.php Passed 13 tests
The main file in "Adshares" v. 0.1.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
60 characters long description:
The easiest way to connect your site to the Adshares network
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
No dangerous file extensions were detected37,921 lines of code in 784 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 642 | 6,403 | 11,958 | 29,222 |
reStructuredText | 90 | 2,433 | 2,162 | 3,384 |
Markdown | 13 | 1,024 | 0 | 3,274 |
JSON | 9 | 0 | 0 | 895 |
C | 1 | 171 | 186 | 860 |
Twig | 10 | 6 | 0 | 137 |
YAML | 2 | 13 | 1 | 48 |
XML | 2 | 8 | 0 | 47 |
HTML | 11 | 0 | 0 | 17 |
C/C++ Header | 1 | 7 | 13 | 15 |
make | 1 | 4 | 0 | 9 |
CSS | 1 | 1 | 0 | 8 |
m4 | 1 | 2 | 1 | 5 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.35 |
Average class complexity | 4.94 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 159.00 |
Average method complexity | 2.25 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 69.00 |
Code structure | ||
---|---|---|
Namespaces | 32 | |
Interfaces | 57 | |
Traits | 2 | |
Classes | 612 | |
▷ Abstract classes | 16 | 2.61% |
▷ Concrete classes | 596 | 97.39% |
▷ Final classes | 13 | 2.18% |
Methods | 2,168 | |
▷ Static methods | 99 | 4.57% |
▷ Public methods | 1,837 | 84.73% |
▷ Protected methods | 169 | 7.80% |
▷ Private methods | 162 | 7.47% |
Functions | 224 | |
▷ Named functions | 128 | 57.14% |
▷ Anonymous functions | 96 | 42.86% |
Constants | 112 | |
▷ Global constants | 7 | 6.25% |
▷ Class constants | 105 | 93.75% |
▷ Public constants | 105 | 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 are no PNG files in this plugin