about summary refs log tree commit diff
path: root/src/test/ui/panic-while-printing.rs
AgeCommit message (Collapse)AuthorLines
2020-11-10Merge set_panic and set_print into set_output_capture.Mara Bos-3/+3
There were no use cases for setting them separately. Merging them simplifies some things.
2020-11-10Use Vec<u8> for LOCAL_STD{OUT,ERR} instead of dyn Write.Mara Bos-13/+2
It was only ever used with Vec<u8> anyway. This simplifies some things. - It no longer needs to be flushed, because that's a no-op anyway for a Vec<u8>. - Writing to a Vec<u8> never fails. - No #[cfg(test)] code is needed anymore to use `realstd` instead of `std`, because Vec comes from alloc, not std (like Write).
2020-11-10Update tests for updated set_panic.Mara Bos-7/+4
2020-10-22Capture output from threads spawned in testsTyler Mandry-2/+17
Fixes #42474.
2020-03-18std: Don't abort process when printing panics in testsAlex Crichton-0/+24
This commit fixes an issue when using `set_print` and friends, notably used by libtest, to avoid aborting the process if printing panics. This previously panicked due to borrowing a mutable `RefCell` twice, and this is worked around by borrowing these cells for less time, instead taking out and removing contents temporarily. Closes #69558