94% gp-create-test-post

Code Review | GP Create Test Post

WordPress plugin GP Create Test Post scored 94% from 54 tests.

About plugin

  • Plugin page: gp-create-test-post
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.3
  • WordPress version: 5.8.1
  • First release: Oct 29, 2015
  • Latest release: Aug 3, 2016
  • Number of updates: 12
  • Update frequency: every 23.3 days
  • Top authors: giangmd93 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 495 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼142.81ms] Passed 4 tests

This is a short check of server-side resources used by GP Create Test Post
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1238.60 ▲16.26
Dashboard /wp-admin3.06 ▲0.0145.28 ▼1.57
Posts /wp-admin/edit.php3.12 ▲0.0148.36 ▼0.29
Add New Post /wp-admin/post-new.php5.43 ▼0.0199.95 ▼567.78
Media Library /wp-admin/upload.php3.01 ▲0.0135.83 ▼1.58
GP Create Test Post /wp-admin/options-general.php?page=gp-create-test-post2.9828.49

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 18 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for GP Create Test Post
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,710 ▲11415.78 ▲0.1910.34 ▼1.2563.91 ▲11.57
Dashboard /wp-admin2,979 ▲485.95 ▲0.04145.37 ▼11.8995.71 ▼28.36
Posts /wp-admin/edit.php2,748 ▲92.72 ▲0.0165.86 ▼4.9878.78 ▼17.68
Add New Post /wp-admin/post-new.php1,690 ▲717.22 ▲1.00377.47 ▼23.86125.49 ▼2.05
Media Library /wp-admin/upload.php1,816 ▲65.00 ▼0.01151.79 ▼6.28130.46 ▼1.51
GP Create Test Post /wp-admin/options-general.php?page=gp-create-test-post1,1522.0962.8054.16

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
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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 take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gp-create-test-post/gp-create-test-post.php:39

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
3 plugin tags: post test, create genaral post, create test post

gp-create-test-post/gp-create-test-post.php Passed 13 tests

The main file in "GP Create Test Post" v. 1.2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
58 characters long description:
Create test posts for the first install Wordpress Project.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin9,040 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
CSS59257,047
JavaScript35771971,563
SVG100288
PHP12022142

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 code0.18
Average class complexity14.00
▷ Minimum class complexity14.00
▷ Maximum class complexity14.00
Average method complexity2.86
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot.png15.99KB10.31KB▼ 35.49%