Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tests for WP_Classic_To_Block_Menu_Converter class #51410

Merged
merged 6 commits into from
Jun 12, 2023

Conversation

getdave
Copy link
Contributor

@getdave getdave commented Jun 12, 2023

What?

Adds direct test coverage for WP_Classic_To_Block_Menu_Converter.

Why?

Tests provider confidence. We also need these in order to ease the merge into Core.

How?

  • Write PHP Unit tests
  • Improve code against tests.

Testing Instructions

Run

npm run test:unit:php -- --filter WP_Classic_To_Block_Menu_Converter_Test --order-by=random

Testing Instructions for Keyboard

Screenshots or screencast

@getdave getdave added the [Type] Code Quality Issues or PRs that relate to code quality label Jun 12, 2023
@getdave getdave self-assigned this Jun 12, 2023
@getdave getdave requested a review from scruffian June 12, 2023 10:35
@getdave getdave marked this pull request as ready for review June 12, 2023 10:35
@getdave getdave enabled auto-merge (squash) June 12, 2023 15:10
@getdave getdave merged commit 625b2de into trunk Jun 12, 2023
@getdave getdave deleted the add/tests-for-menu-converter-class branch June 12, 2023 15:17
@github-actions github-actions bot added this to the Gutenberg 16.1 milestone Jun 12, 2023
@ramonjd ramonjd added the Needs PHP backport Needs PHP backport to Core label Jun 13, 2023
@ramonjd ramonjd removed the Needs PHP backport Needs PHP backport to Core label Jun 30, 2023
sethrubenstein pushed a commit to pewresearch/gutenberg that referenced this pull request Jul 13, 2023
* Initial happy path

* Add test and code for invalid arguments

* Add more edge cases

* Add correct docblocks

* Ensure all asserts have message arg

* Please the PHPCS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants