Benchmarks
Plugin footprint 75% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The following installer errors require your attention
- Install procedure had errors
- > Notice in wp-content/plugins/templatic-google-amp/templatic-amp.php+42
Trying to access array offset on value of type bool
Server metrics [RAM: ▲0.02MB] [CPU: ▼137.89ms] Passed 4 tests
A check of server-side resources used by Templatic-Google-AMP
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.85 ▲0.13 | 31.98 ▲11.04 |
Dashboard /wp-admin | 3.08 ▲0.02 | 44.69 ▼2.48 |
Posts /wp-admin/edit.php | 3.13 ▲0.02 | 43.05 ▲0.75 |
Add New Post /wp-admin/post-new.php | 5.44 ▲0.01 | 92.27 ▼556.00 |
Media Library /wp-admin/upload.php | 3.02 ▲0.02 | 30.66 ▲6.19 |
Server storage [IO: ▲0.21MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 36 new files
Database: no new tables, 2 new options
New WordPress options |
---|
tmpl_amp_plugin_active |
tmpl_amp_settings |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Templatic-Google-AMP
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,728 ▲132 | 15.81 ▲0.36 | 9.15 ▲1.56 | 48.07 ▲4.07 |
Dashboard /wp-admin | 2,979 ▲45 | 5.91 ▼0.22 | 132.98 ▼8.39 | 131.27 ▲21.48 |
Posts /wp-admin/edit.php | 2,770 ▲34 | 2.68 ▲0.00 | 60.34 ▼0.03 | 94.88 ▲11.09 |
Add New Post /wp-admin/post-new.php | 1,695 ▼177 | 18.83 ▼0.32 | 374.78 ▲3.46 | 103.05 ▼11.26 |
Media Library /wp-admin/upload.php | 1,764 ▼46 | 5.00 ▼0.03 | 135.98 ▼24.96 | 144.80 ▲23.84 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 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 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test
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
Please fix the following items
- 1× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/templatic-google-amp/templates/templatic/style.php
- 23× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_embed_register_handler() in wp-content/plugins/templatic-google-amp/includes/core/handler/youtube_handler.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function has_post_thumbnail() in wp-content/plugins/templatic-google-amp/templates/templatic/content.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/templatic-google-amp/includes/core/handler/common_filter.php:24
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/templatic-google-amp/templates/templatic/footer.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_title() in wp-content/plugins/templatic-google-amp/templates/templatic/header.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function get_header() in wp-content/plugins/templatic-google-amp/templates/templatic/page.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/templatic-google-amp/includes/admin/form.php:31
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_embed_register_handler() in wp-content/plugins/templatic-google-amp/includes/core/handler/vimeo_handler.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function get_header() in wp-content/plugins/templatic-google-amp/templates/templatic/single.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_embed_register_handler() in wp-content/plugins/templatic-google-amp/includes/core/handler/twitter_handler.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)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 86% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
- Screenshots: Please add images for these screenshots: #1 (This is how you can set the backend settings for AMP), #2 (This is how will see the detail page with amp)
templatic-google-amp/templatic-amp.php 77% from 13 tests
This is the main PHP file of "Templatic-Google-AMP" version 0.0.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
- Main file name: The principal plugin file should be the same as the plugin slug ("templatic-google-amp.php" instead of "templatic-amp.php")
- Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
- Description: The description should be shorter than 140 characters (currently 144 characters long)
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
Success! There were no dangerous files found in this plugin1,218 lines of code in 30 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 28 | 224 | 180 | 1,074 |
PO File | 1 | 36 | 39 | 98 |
CSS | 1 | 1 | 0 | 46 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 2.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3.00 |
Average method complexity | 1.40 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 5 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 5 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 29 | |
▷ Named functions | 29 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
4 PNG files occupy 0.16MB with 0.10MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
(invalid) screenshot-2.png | 114.75KB | 0.00KB | ▼ 100.00% |
assets/images/placeholder-icon.png | 0.85KB | 0.82KB | ▼ 3.12% |
(invalid) screenshot-1.png | 42.39KB | 0.00KB | ▼ 100.00% |
assets/images/templatic-logo.png | 1.26KB | 0.74KB | ▼ 41.81% |