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
Installer ran successfully
Server metrics [RAM: ▲0.09MB] [CPU: ▼4.25ms] Passed 4 tests
A check of server-side resources used by APPRL
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.48 ▲0.02 | 44.93 ▲4.54 |
Dashboard /wp-admin | 3.39 ▲0.09 | 46.40 ▼4.95 |
Posts /wp-admin/edit.php | 3.51 ▲0.15 | 44.88 ▼2.98 |
Add New Post /wp-admin/post-new.php | 6.44 ▲0.56 | 86.45 ▼13.61 |
Media Library /wp-admin/upload.php | 3.32 ▲0.09 | 39.82 ▲8.99 |
APPRL /wp-admin/options-general.php?page=apprl-config | 3.75 | 35.31 |
Server storage [IO: ▲7.47MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 1,253 new files
Database: no new tables, 9 new options
New WordPress options |
---|
apprl_version |
widget_theysaidso_widget |
widget_recent-comments |
apprl_activation_date |
apprl_cron_running |
db_upgraded |
can_compress_scripts |
theysaidso_admin_options |
widget_recent-posts |
Browser metrics Passed 4 tests
An overview of browser requirements for APPRL
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,806 ▲71 | 13.41 ▼0.98 | 1.81 ▲0.05 | 42.60 ▲1.27 |
Dashboard /wp-admin | 2,212 ▲21 | 5.88 ▲0.97 | 93.89 ▼10.67 | 44.20 ▲2.92 |
Posts /wp-admin/edit.php | 2,095 ▲6 | 2.05 ▼0.02 | 35.43 ▼8.23 | 36.22 ▲0.45 |
Add New Post /wp-admin/post-new.php | 1,519 ▼23 | 17.77 ▼0.72 | 678.92 ▲72.75 | 56.61 ▼1.57 |
Media Library /wp-admin/upload.php | 1,397 ▲9 | 4.21 ▲0.00 | 105.17 ▲6.41 | 45.34 ▲3.59 |
APPRL /wp-admin/options-general.php?page=apprl-config | 764 | 2.05 | 26.21 | 24.24 |
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
Please fix the following items
- The uninstall procedure has failed, leaving 8 options in the database
- can_compress_scripts
- widget_recent-comments
- widget_theysaidso_widget
- apprl_cron_running
- widget_recent-posts
- apprl_activation_date
- theysaidso_admin_options
- db_upgraded
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)
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: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
- 2× PHP files output text when accessed directly:
- > /wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/squizlabs/php_codesniffer/scripts/build-phar.php
- > /wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/phpunit/phpunit/build/assertions.php
- 709× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Interface 'PHP_CodeSniffer_Sniff' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/WhiteSpace/DisallowSpaceIndentSniff.php:28
- > PHP Fatal error
Uncaught Error: Class 'OAuth\\OAuth2\\Service\\AbstractService' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/src/OAuth/OAuth2/Service/Microsoft.php:13
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_MockObject_Matcher_StatelessInvocation' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/phpunit/phpunit-mock-objects/PHPUnit/Framework/MockObject/Matcher/MethodName.php:60
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/phpunit/php-code-coverage/Tests/_files/NamespaceCoverageClassTest.php:2
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/symfony/http-foundation/Tests/StreamedResponseTest.php:17
- > PHP Fatal error
Uncaught Error: Class 'OAuth\\OAuth2\\Service\\AbstractService' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/src/OAuth/OAuth2/Service/Vkontakte.php:13
- > PHP Fatal error
Uncaught Error: Interface 'PHPUnit_Framework_MockObject_Stub' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/phpunit/phpunit-mock-objects/PHPUnit/Framework/MockObject/Stub/ConsecutiveCalls.php:58
- > PHP Warning
require_once(PHP/Token/Stream.php): failed to open stream: No such file or directory in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/phpunit/php-token-stream/Tests/Token/NamespaceTest.php on line 53
- > PHP Fatal error
Uncaught Error: Interface 'PHP_CodeSniffer_Sniff' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/Commenting/DocCommentAlignmentSniff.php:30
- > PHP Fatal error
Uncaught Error: Class 'OAuth\\OAuth2\\Service\\AbstractService' not found in wp-content/plugins/apprl/lib/PHPoAuthLib/src/OAuth/OAuth2/Service/Delicious.php:27
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: affiliate, fashion, affiliate marketing
apprl/apprl.php 92% from 13 tests
The primary PHP file in "APPRL" version 1.0.3 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
- Description: The description should be shorter than 140 characters (currently 229 characters long)
Code Analysis 3% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Please fix the following items
- Do not include executable or dangerous files in your plugin
- .bat - Batch File in Windows
- ☣ wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/squizlabs/php_codesniffer/scripts/phpcbf.bat
- ☣ wp-content/plugins/apprl/lib/PHPoAuthLib/vendor/squizlabs/php_codesniffer/scripts/phpcs.bat
- .bat - Batch File in Windows
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 944 | 50,302 | 97,294 | 81,580 |
XML | 145 | 203 | 128 | 4,890 |
YAML | 26 | 147 | 89 | 3,249 |
JSON | 12 | 2 | 0 | 1,071 |
Ant | 4 | 102 | 0 | 678 |
CSS | 5 | 207 | 168 | 572 |
Markdown | 18 | 183 | 0 | 486 |
XSD | 1 | 0 | 0 | 251 |
HTML | 1 | 1 | 0 | 43 |
JavaScript | 7 | 0 | 10 | 22 |
DOS Batch | 2 | 2 | 22 | 16 |
SVG | 1 | 0 | 0 | 1 |
PHP code 50% from 2 tests
An overview of cyclomatic complexity and code structure
The following items need your attention
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 215)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 10.52 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 502.00 |
Average method complexity | 3.15 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 215.00 |
Code structure | ||
---|---|---|
Namespaces | 49 | |
Interfaces | 51 | |
Traits | 0 | |
Classes | 979 | |
▷ Abstract classes | 34 | 3.47% |
▷ Concrete classes | 945 | 96.53% |
▷ Final classes | 1 | 0.11% |
Methods | 4,784 | |
▷ Static methods | 387 | 8.09% |
▷ Public methods | 4,063 | 84.93% |
▷ Protected methods | 616 | 12.88% |
▷ Private methods | 105 | 2.19% |
Functions | 211 | |
▷ Named functions | 156 | 73.93% |
▷ Anonymous functions | 55 | 26.07% |
Constants | 622 | |
▷ Global constants | 106 | 17.04% |
▷ Class constants | 516 | 82.96% |
▷ Public constants | 516 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
6 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/banner-1544x500.png | 5.39KB | 6.10KB | 0.00% |
assets/icon-256x256.png | 1.91KB | 3.11KB | 0.00% |
lib/PHPoAuthLib/vendor/phpunit/php-code-coverage/PHP/CodeCoverage/Report/HTML/Renderer/Template/img/glyphicons-halflings.png | 12.50KB | 10.35KB | ▼ 17.19% |
assets/icon-128x128.png | 0.98KB | 1.72KB | 0.00% |
lib/PHPoAuthLib/vendor/phpunit/php-code-coverage/PHP/CodeCoverage/Report/HTML/Renderer/Template/img/glyphicons-halflings-white.png | 8.57KB | 9.20KB | 0.00% |