94% danixland-asciinema

Code Review | danixland asciinema shortcode

WordPress plugin danixland asciinema shortcode scored 94% from 54 tests.

About plugin

  • Plugin page: danixland-asciinema
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.5
  • WordPress version: 5.9.2
  • First release: Jan 22, 2016
  • Latest release: Apr 1, 2016
  • Number of updates: 9
  • Update frequency: every 150.7 days
  • Top authors: danixland (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 688 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.02MB] [CPU: ▼295.47ms] Passed 4 tests

Analyzing server-side resources used by danixland asciinema shortcode
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0154.28 ▲2.33
Dashboard /wp-admin3.41 ▲0.0035.41 ▲0.83
Posts /wp-admin/edit.php3.64 ▲0.0037.46 ▲0.12
Add New Post /wp-admin/post-new.php6.88 ▼0.0994.11 ▼1,184.12
Media Library /wp-admin/upload.php3.29 ▲0.0025.06 ▲1.31

Server storage [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 3 tests

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for danixland asciinema shortcode
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,763 ▲2115.78 ▲0.135.75 ▲0.042.37 ▲0.26
Dashboard /wp-admin2,892 ▲346.07 ▼0.11116.25 ▼23.44169.90 ▲5.36
Posts /wp-admin/edit.php2,688 ▼63.23 ▼0.0064.74 ▲0.98141.34 ▲1.53
Add New Post /wp-admin/post-new.php1,661 ▼016.56 ▲0.58409.63 ▲23.25158.56 ▲3.58
Media Library /wp-admin/upload.php1,698 ▼05.45 ▼0.02141.36 ▼0.98195.52 ▲12.43

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 2× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/danixland-asciinema/danixland-asciinema.php
    • > /wp-content/plugins/danixland-asciinema/index.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: asciinema, video, shortcode

danixland-asciinema/danixland-asciinema.php Passed 13 tests

"danixland asciinema shortcode" version 0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
60 characters long description:
A simple shortcode plugin to embed videos from asciinema.org

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected23 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP251523

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
No PNG files were detected