Opened 4 years ago

Closed 3 years ago

#31543 closed New feature (wontfix)

Default output buffering on in tests

Reported by: Adam Johnson Owned by: Aly yasser
Component: Testing framework Version: dev
Severity: Normal Keywords:
Cc: Baptiste Mispelon, Carlton Gibson Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Following #31370, the --buffer option is supported for both parallel and non-parallel tests.

I think we should default to turning it *on* for all users, and provide a --no-buffer option to disable this behaviour.

This will improve output for many users, and increase speed for those projects whose tests currently print a lot of output. It has the risk of breaking some workflows of extracting information from tests ˙using print(), but since the output is only hidden for passing tests, I think this should be fairly niche.

Change History (4)

comment:1 by Ahmad Abdallah, 4 years ago

+1 on making this change. As already pointed out, eliminating unnecessary output will increase the speed of running tests. The associated risk of not seeing a print statement can be easily dealt with by using the --no-buffer option.

This will remove a lot of unnecessary clutter.

Last edited 4 years ago by Ahmad Abdallah (previous) (diff)

comment:2 by Ahmad Abdallah, 4 years ago

Triage Stage: UnreviewedAccepted

comment:3 by Aly yasser, 4 years ago

Owner: changed from nobody to Aly yasser
Status: newassigned

comment:4 by Mariusz Felisiak, 3 years ago

Cc: Carlton Gibson added
Resolution: wontfix
Status: assignedclosed
Triage Stage: AcceptedUnreviewed

IMO we shouldn't change the current behavior, it's consistent with Python's unittest. Folks who are concerned here can add the --buffer flag (it's not much of a burden.)

Note: See TracTickets for help on using tickets.
Back to Top