diff options
author | Christian Stenger <christian.stenger@qt.io> | 2019-11-06 14:26:40 +0100 |
---|---|---|
committer | Christian Stenger <christian.stenger@qt.io> | 2019-11-13 13:09:00 +0000 |
commit | 333b8f98128b7b822e97cc7d51f79485b4c23fb9 (patch) | |
tree | 032f86a57385a915bba6893750ecc264b6523451 /src/plugins/autotest/testoutputreader.h | |
parent | e58f37606803a561ec9470dab049a3618cdb857f (diff) |
AutoTest: Allow colored commandline output
Some test frameworks allow to print their output colorful
to further indicate meanings of messages or test results.
Provide a highlighter for the textual output of the results
and enable this functionality for GTest and Boost UTF.
Keep at least a small backdoor for overwriting this by
the user.
Fixes: QTCREATORBUG-22297
Change-Id: Iddd2b734416de807635d90c6519553081f7372f2
Reviewed-by: David Schulz <david.schulz@qt.io>
Diffstat (limited to 'src/plugins/autotest/testoutputreader.h')
-rw-r--r-- | src/plugins/autotest/testoutputreader.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/autotest/testoutputreader.h b/src/plugins/autotest/testoutputreader.h index 6e8409604a..bd065eaf76 100644 --- a/src/plugins/autotest/testoutputreader.h +++ b/src/plugins/autotest/testoutputreader.h @@ -34,8 +34,6 @@ namespace Autotest { -enum class OutputChannel { StdOut, StdErr }; - class TestOutputReader : public QObject { Q_OBJECT @@ -54,9 +52,11 @@ public: void setId(const QString &id) { m_id = id; } QString id() const { return m_id; } + void resetCommandlineColor(); signals: void newOutputLineAvailable(const QByteArray &outputLine, OutputChannel channel); protected: + QString removeCommandlineColors(const QString &original); virtual void processOutputLine(const QByteArray &outputLine) = 0; virtual TestResultPtr createDefaultResult() const = 0; |