Dedent a block of code in a namespace for consistency with the rest of the block

Change-Id: I98920db658547f5301d31ffdc9efb6fdd6f6fc5a
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
This commit is contained in:
Edward Welbourne 2018-10-18 09:27:52 +02:00
parent b22e50acda
commit e089989bac

View File

@ -282,17 +282,17 @@ namespace QTestPrivate
namespace QTest
{
class WatchDog;
class WatchDog;
static QObject *currentTestObject = 0;
static QString mainSourcePath;
static QObject *currentTestObject = 0;
static QString mainSourcePath;
#if defined(Q_OS_MACOS)
bool macNeedsActivate = false;
IOPMAssertionID powerID;
bool macNeedsActivate = false;
IOPMAssertionID powerID;
#endif
class TestMethods {
class TestMethods {
Q_DISABLE_COPY(TestMethods)
public:
typedef std::vector<QMetaMethod> MetaMethods;
@ -303,7 +303,7 @@ namespace QTest
static QMetaMethod findMethod(const QObject *obj, const char *signature);
private:
private:
bool invokeTest(int index, const char *data, WatchDog *watchDog) const;
void invokeTestOnData(int index) const;
@ -314,16 +314,16 @@ namespace QTest
QMetaMethod m_cleanupMethod;
MetaMethods m_methods;
};
};
TestMethods::TestMethods(const QObject *o, const MetaMethods &m)
TestMethods::TestMethods(const QObject *o, const MetaMethods &m)
: m_initTestCaseMethod(TestMethods::findMethod(o, "initTestCase()"))
, m_initTestCaseDataMethod(TestMethods::findMethod(o, "initTestCase_data()"))
, m_cleanupTestCaseMethod(TestMethods::findMethod(o, "cleanupTestCase()"))
, m_initMethod(TestMethods::findMethod(o, "init()"))
, m_cleanupMethod(TestMethods::findMethod(o, "cleanup()"))
, m_methods(m)
{
{
if (m.empty()) {
const QMetaObject *metaObject = o->metaObject();
const int count = metaObject->methodCount();
@ -334,22 +334,22 @@ namespace QTest
m_methods.push_back(me);
}
}
}
}
QMetaMethod TestMethods::findMethod(const QObject *obj, const char *signature)
{
QMetaMethod TestMethods::findMethod(const QObject *obj, const char *signature)
{
const QMetaObject *metaObject = obj->metaObject();
const int funcIndex = metaObject->indexOfMethod(signature);
return funcIndex >= 0 ? metaObject->method(funcIndex) : QMetaMethod();
}
}
static int keyDelay = -1;
static int mouseDelay = -1;
static int eventDelay = -1;
static int keyDelay = -1;
static int mouseDelay = -1;
static int eventDelay = -1;
#if QT_CONFIG(thread)
static int timeout = -1;
static int timeout = -1;
#endif
static bool noCrashHandler = false;
static bool noCrashHandler = false;
/*! \internal
Invoke a method of the object without generating warning if the method does not exist