Skip to content

feat: backfill Settings and Example modules#15

Merged
justlevine merged 5 commits intomainfrom
feat/backfill-examples
Mar 23, 2026
Merged

feat: backfill Settings and Example modules#15
justlevine merged 5 commits intomainfrom
feat/backfill-examples

Conversation

@justlevine
Copy link
Collaborator

@justlevine justlevine commented Mar 22, 2026

What

Adds example modules, and reorganizes the tests to follow the namespaces

Why

Backfilling usage examples.

Related Issue(s):

How

Testing Instructions

Screenshots

Additional Info

Checklist

Open WordPress Playground Preview

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR backfills “Settings” and “Example” modules into the plugin skeleton, including a basic admin settings screen/template and corresponding unit tests organized by module namespaces.

Changes:

  • Adds Modules\Example (CPT, taxonomy, meta, REST controller) and Modules\Settings (settings registration + admin screen).
  • Updates Core\Assets to separate frontend/admin/editor asset registration hooks.
  • Reorganizes/adds PHPUnit tests to mirror module namespaces and updates development/docs scaffolding notes.

Reviewed changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
tests/php/Unit/Modules/Settings/SettingsTest.php Adds unit tests for settings registration and option helper.
tests/php/Unit/Modules/ExampleTest.php Adds a smoke test for module hook registration.
tests/php/Unit/Modules/Example/Example_TaxonomyTest.php Adds unit tests for taxonomy registration and associations.
tests/php/Unit/Modules/Example/Example_REST_ControllerTest.php Adds unit tests for REST controller response and permissions.
tests/php/Unit/Modules/Example/Example_Post_Type_MetaTest.php Adds unit tests for meta registration, sanitization, and REST updates.
tests/php/Unit/Modules/Example/Example_Post_TypeTest.php Adds unit tests for CPT registration and taxonomy association.
tests/php/Unit/Modules/CLITest.php Moves CLI tests into the Unit\Modules namespace.
tests/php/Unit/Modules/CLI/HealthcheckTest.php Updates namespace/package tags to match module structure.
tests/php/Unit/Modules/Admin/Admin_ScreenTest.php Adds unit tests for the settings admin screen/menu integration.
tests/php/Unit/Core/TemplatesTest.php Moves Templates tests into the Unit\Core namespace.
tests/php/Unit/Core/AssetsTest.php Updates Assets tests for new admin/editor registration methods.
tests/js/setup.ts Removes unnecessary Jest mocks from setup.
templates/admin-screen.php Adds the admin screen template markup.
plugin-skeleton-d.php Removes unused basename constant.
inc/Modules/Settings/Settings.php Implements settings registration and an option helper.
inc/Modules/Settings/Admin_Screen.php Implements admin settings screen + plugin action link + script enqueue.
inc/Modules/Example/Example_Taxonomy.php Adds an example taxonomy implementation.
inc/Modules/Example/Example_REST_Controller.php Adds an example REST controller implementation.
inc/Modules/Example/Example_Post_Type_Meta.php Adds example post meta registration with REST exposure.
inc/Modules/Example/Example_Post_Type.php Adds an example CPT implementation.
inc/Modules/Example.php Adds the Example module bootstrap/registrable list.
inc/Main.php Registers the new modules in the plugin bootstrap.
inc/Core/Assets.php Splits asset registration into frontend/admin/editor and updates hooks.
docs/DEVELOPMENT.md Updates module directory layout and wp-env command examples.
README.md Updates scaffolding/todo documentation to reflect new examples.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@codecov
Copy link

codecov bot commented Mar 23, 2026

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

@justlevine justlevine merged commit bbe8008 into main Mar 23, 2026
18 checks passed
@justlevine justlevine deleted the feat/backfill-examples branch March 23, 2026 00:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants