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

Restore gutenberg_ prefix to function calls in PHPUnit tests #46662

Merged
merged 1 commit into from
Dec 20, 2022

Conversation

danielbachhuber
Copy link
Member

@danielbachhuber danielbachhuber commented Dec 19, 2022

Discovered in #46435
See some conversation in Slack https://wordpress.slack.com/archives/C02QB2JS7/p1671470350718839

What?

Restores the gutenberg_ prefix to function calls in the Navigation Link PHPUnit tests.

Why?

The prefixes were erroneously removed in #40657. Without the prefix, the tests run against the WordPress core version of the functions, instead of the version in Gutenberg the plugin.

Testing Instructions

All tests should pass.

@danielbachhuber danielbachhuber added the [Type] Bug An existing feature does not function as intended label Dec 19, 2022
@danielbachhuber danielbachhuber self-assigned this Dec 19, 2022
@danielbachhuber danielbachhuber added the [Type] Build Tooling Issues or PRs related to build tooling label Dec 19, 2022
Copy link
Contributor

@desrosj desrosj left a comment

Choose a reason for hiding this comment

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

Good find!

Confirmed locally that gutenberg_render_block_core_navigation_link() does not exist until the build script is run. Then it does within the build directory and is used instead of the Core version of render_block_core_navigation_link().

@desrosj
Copy link
Contributor

desrosj commented Dec 19, 2022

Also, looks like the performance tests only failed because of a timeout issue. Restarted just to double check the results.

@danielbachhuber danielbachhuber force-pushed the fix/navigation-link-block-test-prefix branch from fd3abda to 5370890 Compare December 20, 2022 11:45
@danielbachhuber danielbachhuber merged commit 2589617 into trunk Dec 20, 2022
@danielbachhuber danielbachhuber deleted the fix/navigation-link-block-test-prefix branch December 20, 2022 12:29
@github-actions github-actions bot added this to the Gutenberg 14.9 milestone Dec 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Bug An existing feature does not function as intended [Type] Build Tooling Issues or PRs related to build tooling
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants