catch2/tests/SelfTest/IntrospectiveTests
Jeremy Rifkin 8ce2426e53
Handle ANSI escape sequences when performing column wrapping (#2849)
This PR adds functionality to skip around ANSI escape sequences in catch_textflow so they do not contribute to line length and line wrapping code does not split escape sequences in the middle. I've implemented this by creating a AnsiSkippingString abstraction that has a bidirectional iterator that can skip around escape sequences while iterating. Additionally I refactored Column::const_iterator to be iterator-based rather than index-based so this abstraction is a simple drop-in for std::string.

Currently only color sequences are handled, other escape sequences are left unaffected.

Motivation: Text with ANSI color sequences gets messed up when being output by Catch2 #2833.
2024-05-04 23:43:52 +02:00
..
Algorithms.tests.cpp Add Catch::Detail::is_permutation that supports sentinels 2023-02-06 15:29:01 +01:00
AssertionHandler.tests.cpp Assert Info reset need to also reset result disposition to normal to handle uncaught exception correctly (#2723) 2023-08-07 22:07:31 +02:00
Clara.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
CmdLine.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
CmdLineHelpers.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
ColourImpl.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
Details.tests.cpp Fix various useful clang-tidy warnings 2024-03-01 21:24:45 +01:00
FloatingPoint.tests.cpp Add tests for scaled ULP distance between +/- FLT/DBL_MAX 2024-01-14 21:15:02 +01:00
GeneratorsImpl.tests.cpp Fix various useful clang-tidy warnings 2024-03-01 21:24:45 +01:00
Integer.tests.cpp Optimize 64x64 extended multiplication implementation 2024-04-03 13:28:25 +02:00
InternalBenchmark.tests.cpp Don't include numerically unstable tests in approvals 2024-04-30 19:21:27 +02:00
Json.tests.cpp Fix special character escaping in JsonWriter 2023-11-14 23:35:22 +01:00
Parse.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
PartTracker.tests.cpp Avoid allocations when looking for trackers 2023-01-29 10:14:20 +01:00
RandomNumberGeneration.tests.cpp Fix preprocessor check for enabling FP reproducibility tests 2024-04-06 20:27:15 +02:00
Reporters.tests.cpp Fix various useful clang-tidy warnings 2024-03-01 21:24:45 +01:00
Sharding.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
Stream.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
String.tests.cpp Fix UDL definitions for C++23 2023-10-28 21:35:03 +02:00
StringManip.tests.cpp less copies and allocations in replaceInPlace 2024-03-01 21:24:45 +01:00
Tag.tests.cpp Improve error messages for TEST_CASE tag parsing errors 2023-05-20 21:13:48 +02:00
TestCaseInfoHasher.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
TestSpec.tests.cpp Fix various useful clang-tidy warnings 2024-03-01 21:24:45 +01:00
TestSpecParser.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
TextFlow.tests.cpp Handle ANSI escape sequences when performing column wrapping (#2849) 2024-05-04 23:43:52 +02:00
ToString.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
Traits.tests.cpp Support decomposing types that only compare with literal 0 2022-11-04 19:24:44 +01:00
UniquePtr.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00
Xml.tests.cpp Fix references to license file 2022-10-28 11:30:15 +02:00