mirror of
https://github.com/catchorg/Catch2.git
synced 2025-05-25 05:59:24 +00:00
Add --force-colour option to force colour output.
Adding a --force-colour option to force colour output on POSIX systems, provided a debugger is not attached. This allows for Catch to output colours even if STDOUT is not a tty, which can be the case when the test executable is being spawned by a parent process (e.g. CMake's ctest).
This commit is contained in:
parent
7f5615272b
commit
e5280b2c57
5 changed files with 27 additions and 3 deletions
|
@ -170,6 +170,10 @@ namespace Catch {
|
|||
.describe( "set a specific seed for random numbers" )
|
||||
.bind( &setRngSeed, "'time'|number" );
|
||||
|
||||
cli["--force-colour"]
|
||||
.describe( "force colourised output" )
|
||||
.bind( &ConfigData::forceColour );
|
||||
|
||||
return cli;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue