Skip to content

Fix failing header_image_data test - #243

Merged
swissspidy merged 2 commits into
mainfrom
fix/tests
Aug 5, 2026
Merged

Fix failing header_image_data test#243
swissspidy merged 2 commits into
mainfrom
fix/tests

Conversation

@swissspidy

@swissspidy swissspidy commented Aug 5, 2026

Copy link
Copy Markdown
Member

Follow up to wp-cli/extension-command#456

Summary by CodeRabbit

  • Tests
    • Updated search-and-replace validation to reflect the current tabular command output.
    • Added checks confirming the URL value before and after replacement.

@swissspidy swissspidy added this to the 3.0.1 milestone Aug 5, 2026
@swissspidy
swissspidy requested a review from a team as a code owner August 5, 2026 09:06
Copilot AI lite review requested due to automatic review settings August 5, 2026 09:06
@swissspidy swissspidy added the scope:testing Related to testing label Aug 5, 2026
@coderabbitai

coderabbitai Bot commented Aug 5, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@swissspidy, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 56 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 9071f0b0-626d-4777-859f-9265cd1f3c18

📥 Commits

Reviewing files that changed from the base of the PR and between 5227493 and 5efce7a.

📒 Files selected for processing (1)
  • features/search-replace.feature
📝 Walkthrough

Walkthrough

The theme-mod search/replace scenario now checks the current tabular output from wp theme mod get before and after URL replacement.

Changes

Theme mod output assertions

Layer / File(s) Summary
Formatted output checks
features/search-replace.feature
The scenario checks the formatted url output with the original subdomain URL before replacement and the updated domain URL after replacement.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: copilot

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the intended change and matches the stated objective to fix the failing header_image_data test.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Updates the Behat acceptance test for wp search-replace to align with the current wp theme mod get header_image_data output, ensuring the header_image_data.url value is validated before and after running search-replace.

Changes:

  • Adjusted header_image_data assertions from JSON/table-row expectations to matching the current key/value output.
  • Added explicit checks for the URL value both before and after replacement to prevent regressions.
Suppressed comments (1)

features/search-replace.feature:278

  • Same as above: the expected output includes a literal tab character, which is easy to accidentally modify and ties the test to exact formatting. Prefer asserting on the URL substring only.
    Then STDOUT should contain:
      """
        url	https://example.com/foo.jpg
      """

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

Comment thread features/search-replace.feature
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@codecov

codecov Bot commented Aug 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@swissspidy
swissspidy merged commit 5df5c19 into main Aug 5, 2026
63 checks passed
@swissspidy
swissspidy deleted the fix/tests branch August 5, 2026 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope:testing Related to testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants