Skip to content

Commit

Permalink
Eliminate QTestResult::ignoreMessage().
Browse files Browse the repository at this point in the history
The removed function was just a wrapper around QTestLog::ignoreMessage()
and was only called twice (once in qtestcase.cpp and once in
qtdeclarative).  Better to just call the desired function directly and
avoid the indirection.

Change-Id: Ib900f35f5d584e8f323cef9b0e7b4f8a507c199e
Reviewed-by: Rohan McGovern <[email protected]>
  • Loading branch information
Jason McDonald authored and Qt by Nokia committed Jan 30, 2012
1 parent 7934c75 commit f323c70
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 8 deletions.
2 changes: 1 addition & 1 deletion src/testlib/qtestcase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2118,7 +2118,7 @@ void QTest::qWarn(const char *message, const char *file, int line)
*/
void QTest::ignoreMessage(QtMsgType type, const char *message)
{
QTestResult::ignoreMessage(type, message);
QTestLog::ignoreMessage(type, message);
}

/*! \internal
Expand Down
5 changes: 0 additions & 5 deletions src/testlib/qtestresult.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -313,11 +313,6 @@ int QTestResult::skipCount()
return QTestLog::skipCount();
}

void QTestResult::ignoreMessage(QtMsgType type, const char *msg)
{
QTestLog::ignoreMessage(type, msg);
}

bool QTestResult::testFailed()
{
return QTest::failed;
Expand Down
2 changes: 0 additions & 2 deletions src/testlib/qtestresult_p.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@ class Q_TESTLIB_EXPORT QTestResult
static int failCount();
static int skipCount();

static void ignoreMessage(QtMsgType type, const char *msg);

static void addFailure(const char *message, const char *file, int line);
static bool compare(bool success, const char *msg, const char *file, int line);
static bool compare(bool success, const char *msg, char *val1, char *val2,
Expand Down

0 comments on commit f323c70

Please sign in to comment.