forked from qt-creator/qt-creator
Similar to what has been done for boost test - there is special handling when the test applications process exits. This was no more executed since moving over to use the task tree. Change-Id: I982b7e4dfe6de4bbbe75c8d3ec0f62d0c3037f4a Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
37 lines
1.1 KiB
C++
37 lines
1.1 KiB
C++
// Copyright (C) 2016 The Qt Company Ltd.
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
|
|
|
#pragma once
|
|
|
|
#include "../testoutputreader.h"
|
|
|
|
namespace Autotest {
|
|
namespace Internal {
|
|
|
|
class GTestOutputReader : public TestOutputReader
|
|
{
|
|
public:
|
|
GTestOutputReader(Utils::Process *testApplication, const Utils::FilePath &buildDirectory,
|
|
const Utils::FilePath &projectFile);
|
|
protected:
|
|
void processOutputLine(const QByteArray &outputLine) override;
|
|
void processStdError(const QByteArray &outputLine) override;
|
|
TestResult createDefaultResult() const override;
|
|
|
|
private:
|
|
void onDone(int exitCode) override;
|
|
void setCurrentTestCase(const QString &testCase);
|
|
void setCurrentTestSuite(const QString &testSuite);
|
|
void handleDescriptionAndReportResult(const TestResult &testResult);
|
|
|
|
Utils::FilePath m_projectFile;
|
|
QString m_currentTestSuite;
|
|
QString m_currentTestCase;
|
|
QString m_description;
|
|
int m_iteration = 1;
|
|
bool m_testSetStarted = false;
|
|
};
|
|
|
|
} // namespace Internal
|
|
} // namespace Autotest
|