Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Console] Fix testing multiline question#61501

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:6.4fromMatTheCat:ticket_58910
Aug 23, 2025

Conversation

@MatTheCat
Copy link
Contributor

QA
Branch?6.4
Bug fix?yes
New feature?no
Deprecations?no
IssuesFix#58910
LicenseMIT

@fabpot
Copy link
Member

Thank you@MatTheCat.

@fabpotfabpot merged commit5c143ba intosymfony:6.4Aug 23, 2025
11 checks passed
@MatTheCatMatTheCat deleted the ticket_58910 branchAugust 23, 2025 11:28
This was referencedAug 29, 2025
@DaveLiddament
Copy link

FYI: This update has caused a number of my test to fail (see:DaveLiddament/sarb#152) . All my tests passed again when downgrading just the symfony/console package from 6.4.25 to 6.4.24.

The problem I encountered is the addition of the EOT character (x04) added inTesterTrait::createStream

In order to make my tests pass, I have to add in some code the removes the trailing EOT character (if it exists).

As far as I can tell (my package has been used for 7 years) this character does not exist in real applications.
Therefore I'm wondering if the addition of EOT (in some circumstances) is valid, as it does not appear to map what really happens.

If you want to explore this more, then I can try and put together a small reproducer.

PS: Thanks to all the Symfony team and contributors for creating such an amazing framework.

@MatTheCat
Copy link
ContributorAuthor

Thanks for the feedback@DaveLiddament, thex04 character was added to emulate the end of a multiline question’s answer and I didn’t even think new lines could appear in other contexts..!

I guess it should be the developer responsibility to add this character then; will open a PR.

nicolas-grekas added a commit that referenced this pull requestSep 8, 2025
… inputs (MatTheCat)This PR was squashed before being merged into the 6.4 branch.Discussion----------[Console] Don’t automatically append EOT to multiline test inputs| Q             | A| ------------- | ---| Branch?       | 6.4| Bug fix?      | yes| New feature?  | no| Deprecations? | no| Issues        | N/A| License       | MIT#61501 assumed multiline inputs were answers to multiline questions and suffixed them with an EOT character to mark their end.But if you’re directly reading stdin, you can have line breaks without the need for an EOT:#61501 (comment)Since the `TesterTrait` doesn’t know the inputs’ context, this PR reverts this behavior. Multiline questions will still be able to be tested by manually suffixing the answer with an EOT (`x04`) like in the added test.If it is accepted it’ll be followed by a doc PR.Commits-------938fabb [Console] Don’t automatically append EOT to multiline test inputs
nicolas-grekas added a commit that referenced this pull requestSep 8, 2025
…th an EOT (MatTheCat)This PR was merged into the 6.4 branch.Discussion----------[Console] Don’t append a new line to test inputs ending with an EOT| Q             | A| ------------- | ---| Branch?       | 6.4| Bug fix?      | yes| New feature?  | no| Deprecations? | no| Issues        | N/A| License       | MIT#61501 wrote a new line before multiline test inputs’ EOT character, and#61690 wrote it after… so the next input would always be empty.This PR doesn’t write a new line if a test input ends with `\x4` so that the stream matches the inputs.Commits-------74ae155 [Console] Don’t append a new line to test inputs ending with an EOT
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@fabpotfabpotfabpot approved these changes

@chalasrchalasrAwaiting requested review from chalasrchalasr is a code owner

Assignees

No one assigned

Projects

None yet

Milestone

6.4

Development

Successfully merging this pull request may close these issues.

4 participants

@MatTheCat@fabpot@DaveLiddament@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp