Skip to content

ContextHelper::is_in_type_test(): add tests#2721

Merged
jrfnl merged 3 commits intodevelopfrom
is-in-type-test-tests
Apr 27, 2026
Merged

ContextHelper::is_in_type_test(): add tests#2721
jrfnl merged 3 commits intodevelopfrom
is-in-type-test-tests

Conversation

@rodrigoprimo
Copy link
Copy Markdown
Collaborator

Description

In preparation for supporting PHPCS 4.0, this PR adds unit tests for the ContextHelper::is_in_type_test() method.

Suggested changelog entry

N/A

Copy link
Copy Markdown
Member

@jrfnl jrfnl left a comment

Choose a reason for hiding this comment

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

Nicely done! Thanks.

@jrfnl jrfnl added this to the 3.4.0 milestone Apr 23, 2026
Copy link
Copy Markdown
Member

@GaryJones GaryJones left a comment

Choose a reason for hiding this comment

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

Approved, with one suggestion.

Comment thread WordPress/Tests/Helpers/ContextHelper/IsInTypeTestUnitTest.inc Outdated
@rodrigoprimo
Copy link
Copy Markdown
Collaborator Author

I added a new commit with a negative bare variable test as suggested in #2725 (review) for consistency.

@jrfnl jrfnl force-pushed the is-in-type-test-tests branch from 33999b2 to 5447a46 Compare April 27, 2026 13:08
@jrfnl
Copy link
Copy Markdown
Member

jrfnl commented Apr 27, 2026

I've rebased this PR without changes to get passed the imaginary merge conflict.

@jrfnl jrfnl merged commit adaf62d into develop Apr 27, 2026
42 checks passed
@jrfnl jrfnl deleted the is-in-type-test-tests branch April 27, 2026 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants