summaryrefslogtreecommitdiffstats
path: root/src/testlib/qtaptestlogger_p.h
blob: fa4f338bc0040e1c7ef1dd5fac5281016ebdc870 (plain)
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
// Copyright (C) 2022 The Qt Company Ltd.// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only#ifndef QTAPTESTLOGGER_P_H#define QTAPTESTLOGGER_P_H//// W A R N I N G// -------------//// This file is not part of the Qt API. It exists purely as an// implementation detail. This header file may change from version to// version without notice, or even be removed.//// We mean it.//#include <QtTest/private/qabstracttestlogger_p.h> QT_BEGIN_NAMESPACE class QTapTestLogger :public QAbstractTestLogger {public:QTapTestLogger(const char*filename);~QTapTestLogger();voidstartLogging() override;voidstopLogging() override;voidenterTestFunction(const char*) override;voidleaveTestFunction() override {}voidenterTestData(QTestData *data) override;voidaddIncident(IncidentTypes type,const char*description,const char*file =nullptr,int line =0) override;voidaddMessage(MessageTypes type,const QString &message,const char*file =nullptr,int line =0) override;voidaddBenchmarkResult(const QBenchmarkResult &) override {}private:voidoutputTestLine(bool ok,int testNumber,const QTestCharBuffer &directive);voidoutputBuffer(const QTestCharBuffer &buffer);voidflushComments();voidflushMessages();voidbeginYamlish();voidendYamlish(); QTestCharBuffer m_firstExpectedFail; QTestCharBuffer m_comments; QTestCharBuffer m_messages;bool m_gatherMessages =false;}; QT_END_NAMESPACE #endif// QTAPTESTLOGGER_P_H
close