Skip to content

pr: fix expected output in non-UTF-8 merge test - #16161

Merged
sylvestre merged 2 commits into
uutils:mainfrom
Martell0x1:fix/pr-non-utf8-merge-test
Nov 3, 2026
Merged

sylvestre merged 2 commits into
uutils:mainfrom
Martell0x1:fix/pr-non-utf8-merge-test

Conversation

@Martell0x1

@Martell0x1 Martell0x1 commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Fix the expected output of test_merge_non_utf8_input_filename and re-enable the regression test.

Problem

The test expected the final column to be padded to 35 characters. However, pr intentionally does not pad the last cell of a merged row.

This behavior is documented in get_line_for_printing():

// Like GNU pr, the last cell of a row is not padded, so the
// line has no trailing spaces.

The incorrect expectation caused the test to fail even though the formatter was behaving as intended.

Changes

  • Correct the expected output to avoid padding the final column.

Testing

cargo nextest run -E 'test(test_merge_non_utf8_input_filename)'

The test passes with the corrected expectation.

Closes #16147

Copilot AI balanced review requested due to automatic review settings November 3, 2026 10:11

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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

Comment thread tests/by-util/test_pr.rs Resolved
Copilot AI balanced review requested due to automatic review settings November 3, 2026 10:18

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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

@sylvestre
sylvestre merged commit 27854f9 into uutils:main Nov 3, 2026
88 checks passed
@sylvestre

Copy link
Copy Markdown
Contributor

Thanks for your PR

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.

pr: test_merge_non_utf8_input_filename is failing

4 participants