Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.04MB] [CPU: ▼289.63ms] Passed 4 tests
A check of server-side resources used by Simple Portfolio Gallery
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.62 ▲0.10 | 55.62 ▲6.16 |
Dashboard /wp-admin | 3.48 ▲0.07 | 34.60 ▲1.96 |
Posts /wp-admin/edit.php | 3.70 ▲0.06 | 39.14 ▲2.47 |
Add New Post /wp-admin/post-new.php | 6.95 ▼0.03 | 95.56 ▼1,162.73 |
Media Library /wp-admin/upload.php | 3.36 ▲0.06 | 23.91 ▼0.21 |
All Portfolios /wp-admin/edit.php?post_type=portfolios-gallery | 3.39 | 24.53 |
Add New /wp-admin/post-new.php?post_type=portfolios-gallery | 3.71 | 48.09 |
Server storage [IO: ▲3.02MB] [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: 67 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
An overview of browser requirements for Simple Portfolio Gallery
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,972 ▲250 | 16.16 ▲0.54 | 9.63 ▲3.48 | 2.70 ▲0.20 |
Dashboard /wp-admin | 2,926 ▲72 | 6.10 ▼0.19 | 117.12 ▼14.86 | 156.39 ▼2.82 |
Posts /wp-admin/edit.php | 2,722 ▲28 | 3.24 ▲0.01 | 62.47 ▼3.78 | 141.86 ▲1.09 |
Add New Post /wp-admin/post-new.php | 1,684 ▼95 | 16.53 ▼5.17 | 429.19 ▼22.08 | 160.30 ▼4.98 |
Media Library /wp-admin/upload.php | 1,735 ▲40 | 5.52 ▼0.04 | 142.90 ▼0.92 | 183.78 ▼2.82 |
All Portfolios /wp-admin/edit.php?post_type=portfolios-gallery | 1,446 | 3.17 | 60.22 | 116.00 |
Add New /wp-admin/post-new.php?post_type=portfolios-gallery | 3,481 | 9.98 | 193.02 | 223.59 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Uninstaller ran successfully
Smoke tests 75% 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 50% 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
- 2× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Class 'WP_Query' not found in wp-content/plugins/simple-portfolio-gallery/tpls/portfolio-gallery.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/simple-portfolio-gallery/portfolio-image-gallery.php:30
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% 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 to be fixed:
- Donate link: Invalid URI found ("")
- Screenshots: These screenshots require images: #1 (Portfolio Gallery Admin Menu page.), #2 (Single Gallery page.), #3 (The pop-up window containing the portfolio details.)
simple-portfolio-gallery/portfolio-image-gallery.php 92% from 13 tests
Analyzing the main PHP file in "Simple Portfolio Gallery" version 0.1
It is important to fix the following:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("simple-portfolio-gallery.php" instead of "portfolio-image-gallery.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected18,732 lines of code in 50 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 9 | 831 | 196 | 12,467 |
JavaScript | 10 | 948 | 452 | 3,569 |
Sass | 13 | 19 | 22 | 928 |
LESS | 12 | 18 | 27 | 907 |
SVG | 4 | 0 | 0 | 673 |
PHP | 2 | 37 | 21 | 188 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.11 |
Average class complexity | 6.00 |
▷ Minimum class complexity | 6.00 |
▷ Maximum class complexity | 6.00 |
Average method complexity | 1.56 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 4.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 9 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 9 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 1.33MB with 0.95MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 194.30KB | 71.57KB | ▼ 63.17% |
screenshot-2.png | 846.17KB | 180.75KB | ▼ 78.64% |
screenshot-3.png | 319.23KB | 89.43KB | ▼ 71.99% |