mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-26 23:36:11 +01:00
Enable colourized output while in debugger
This commit is contained in:
parent
67914d8b86
commit
169e260e8b
@ -94,9 +94,7 @@ namespace {
|
|||||||
? config->useColour()
|
? config->useColour()
|
||||||
: UseColour::Auto;
|
: UseColour::Auto;
|
||||||
if( colourMode == UseColour::Auto )
|
if( colourMode == UseColour::Auto )
|
||||||
colourMode = !isDebuggerActive()
|
colourMode = UseColour::Yes;
|
||||||
? UseColour::Yes
|
|
||||||
: UseColour::No;
|
|
||||||
return colourMode == UseColour::Yes
|
return colourMode == UseColour::Yes
|
||||||
? &s_instance
|
? &s_instance
|
||||||
: NoColourImpl::instance();
|
: NoColourImpl::instance();
|
||||||
@ -155,7 +153,7 @@ namespace {
|
|||||||
? config->useColour()
|
? config->useColour()
|
||||||
: UseColour::Auto;
|
: UseColour::Auto;
|
||||||
if( colourMode == UseColour::Auto )
|
if( colourMode == UseColour::Auto )
|
||||||
colourMode = (!isDebuggerActive() && isatty(STDOUT_FILENO) )
|
colourMode = isatty(STDOUT_FILENO)
|
||||||
? UseColour::Yes
|
? UseColour::Yes
|
||||||
: UseColour::No;
|
: UseColour::No;
|
||||||
return colourMode == UseColour::Yes
|
return colourMode == UseColour::Yes
|
||||||
|
Loading…
Reference in New Issue
Block a user