Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qxctestlogger_p.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QXCTESTLOGGER_P_H
5#define QXCTESTLOGGER_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtTest/private/qabstracttestlogger_p.h>
19
20#include <dispatch/dispatch.h>
21
25
27
29{
30public:
33
34 void startLogging() override;
35 void stopLogging() override;
36
37 void enterTestFunction(const char *function) override;
38 void leaveTestFunction() override;
39
40 void addIncident(IncidentTypes type, const char *description,
41 const char *file = nullptr, int line = 0) override;
42
44 const char *file = nullptr, int line = 0) override;
45
47
48 static bool canLogTestProgress();
49 static int parseCommandLineArgument(const char *argument);
50
51 static bool isActive();
52
53private:
54 void pushTestRunForTest(XCTest *test, bool start);
55 XCTestRun *popTestRun();
56
57 NSMutableArray<XCTestRun *> *m_testRuns;
58
59 static QXcodeTestLogger *s_currentTestLogger;
60};
61
62
64
65#endif
Base class for test loggers.
IncidentTypes
\value Pass The test ran to completion successfully.
MessageTypes
The members whose names begin with Q describe messages that originate in calls, by the test or code u...
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
static int parseCommandLineArgument(const char *argument)
void addIncident(IncidentTypes type, const char *description, const char *file=nullptr, int line=0) override
This virtual method is called when an event occurs that relates to the resolution of the test.
void leaveTestFunction() override
This virtual method is called after a test function has completed, to match \l enterTestFunction().
static bool canLogTestProgress()
void enterTestFunction(const char *function) override
This virtual method is called before each test function is invoked.
static bool isActive()
~QXcodeTestLogger() override
void stopLogging() override
Called after the end of a test run.
void startLogging() override
Called before the start of a test run.
void addBenchmarkResult(const QBenchmarkResult &result) override
This virtual method is called after a benchmark has been run enough times to produce usable data.
void addMessage(MessageTypes type, const QString &message, const char *file=nullptr, int line=0) override
This is an overloaded member function, provided for convenience. It differs from the above function o...
Combined button and popup list for selecting options.
#define Q_FORWARD_DECLARE_OBJC_CLASS(classname)
GLenum type
GLuint GLsizei const GLchar * message
GLuint start
GLuint64EXT * result
[6]
QFile file
[0]
QDBusArgument argument