GUITESTS: Few compares in tests were wrong way around.

This commit is contained in:
Kimmo Varis 2011-06-17 13:18:42 +03:00
parent 5b940c0c7f
commit 5ec241ee0e
4 changed files with 5 additions and 5 deletions

View File

@ -25,7 +25,7 @@ void TestProjectFile::loadInexisting()
{ {
const QString filepath(QString(SRCDIR) + "/../projectfiles/foo.cppcheck"); const QString filepath(QString(SRCDIR) + "/../projectfiles/foo.cppcheck");
ProjectFile pfile(filepath); ProjectFile pfile(filepath);
QCOMPARE(false, pfile.Read()); QCOMPARE(pfile.Read(), false);
} }
void TestProjectFile::loadSimple() void TestProjectFile::loadSimple()

View File

@ -24,8 +24,8 @@
void TestTranslationHandler::construct() void TestTranslationHandler::construct()
{ {
TranslationHandler handler; TranslationHandler handler;
QCOMPARE(11, handler.GetNames().size()); QCOMPARE(handler.GetNames().size(), 11);
QCOMPARE(QString("en"), handler.GetCurrentLanguage()); QCOMPARE(handler.GetCurrentLanguage(), QString("en"));
} }
QTEST_MAIN(TestTranslationHandler) QTEST_MAIN(TestTranslationHandler)

View File

@ -29,7 +29,7 @@ void TestXmlReportV1::readXml()
XmlReportV1 report(filepath); XmlReportV1 report(filepath);
QVERIFY(report.Open()); QVERIFY(report.Open());
QList<ErrorItem> errors = report.Read(); QList<ErrorItem> errors = report.Read();
QCOMPARE(6, errors.size()); QCOMPARE(errors.size(), 6);
ErrorItem item = errors[0]; ErrorItem item = errors[0];
QCOMPARE(item.file, QString("test.cxx")); QCOMPARE(item.file, QString("test.cxx"));

View File

@ -29,7 +29,7 @@ void TestXmlReportV2::readXml()
XmlReportV2 report(filepath); XmlReportV2 report(filepath);
QVERIFY(report.Open()); QVERIFY(report.Open());
QList<ErrorItem> errors = report.Read(); QList<ErrorItem> errors = report.Read();
QCOMPARE(6, errors.size()); QCOMPARE(errors.size(), 6);
ErrorItem item = errors[0]; ErrorItem item = errors[0];
QCOMPARE(item.file, QString("test.cxx")); QCOMPARE(item.file, QString("test.cxx"));