Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.02MB] [CPU: ▼146.74ms] Passed 4 tests
Analyzing server-side resources used by PhotoSwipe
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.87 ▲0.14 | 38.31 ▲15.88 |
Dashboard /wp-admin | 3.08 ▲0.02 | 39.96 ▼6.16 |
Posts /wp-admin/edit.php | 3.14 ▲0.02 | 48.81 ▼1.72 |
Add New Post /wp-admin/post-new.php | 5.44 ▲0.00 | 88.13 ▼580.26 |
Media Library /wp-admin/upload.php | 3.03 ▲0.02 | 37.28 ▲1.20 |
Server storage [IO: ▲0.45MB] [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: 13 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
A check of browser resources used by PhotoSwipe
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,901 ▲295 | 16.31 ▲0.37 | 14.70 ▲1.95 | 44.89 ▼7.30 |
Dashboard /wp-admin | 2,973 ▲42 | 5.94 ▼0.09 | 138.39 ▼13.98 | 117.52 ▼4.99 |
Posts /wp-admin/edit.php | 2,739 ▲3 | 2.72 ▲0.02 | 66.10 ▼2.31 | 101.21 ▲0.70 |
Add New Post /wp-admin/post-new.php | 1,676 ▲178 | 18.85 ▲0.02 | 400.41 ▲33.40 | 125.41 ▲2.10 |
Media Library /wp-admin/upload.php | 1,810 ▼0 | 5.01 ▼0.00 | 151.39 ▲3.95 | 124.72 ▼0.90 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 50% 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
- 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/photo-swipe/photo-swipe.php:48
- > 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 on the user side
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
- Screenshots: Screenshot #1 (PhotoSwipe Website) image required
photo-swipe/photo-swipe.php Passed 13 tests
The main PHP file in "PhotoSwipe" ver. 4.1.1.1 adds more information about the plugin and also serves as the entry point for this plugin
73 characters long description:
A very light implementation of PhotoSwipe javascript plugin for WordPress
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
Good job! No executable or dangerous file extensions detected3,936 lines of code in 9 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 5 | 944 | 396 | 3,329 |
CSS | 2 | 94 | 87 | 479 |
PHP | 1 | 25 | 26 | 127 |
SVG | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 7 | |
▷ Named functions | 7 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.27MB with 0.10MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
lib/default-skin/default-skin.png | 0.53KB | 0.72KB | 0.00% |
screenshot-1.png | 280.53KB | 80.48KB | ▼ 71.31% |