diff options
| author | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-09-27 15:18:29 +0200 |
|---|---|---|
| committer | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-09-27 15:18:29 +0200 |
| commit | 53a2d7b744d597f0c406c55014e18832874b70b8 (patch) | |
| tree | 83416a34cfdf4cde1e11f5d8729b0265c7b6cbd7 /tests | |
| parent | 84b311a914165ed4183324a5881a45deadfb62d0 (diff) | |
| download | qxmpp-53a2d7b744d597f0c406c55014e18832874b70b8.tar.gz | |
split qxmppmessage tests
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/all/all.pro | 2 | ||||
| -rw-r--r-- | tests/all/message.h | 44 | ||||
| -rw-r--r-- | tests/qxmppmessage/qxmppmessage.pro | 3 | ||||
| -rw-r--r-- | tests/qxmppmessage/tst_qxmppmessage.cpp (renamed from tests/all/message.cpp) | 23 | ||||
| -rw-r--r-- | tests/tests.pro | 6 |
5 files changed, 30 insertions, 48 deletions
diff --git a/tests/all/all.pro b/tests/all/all.pro index 9141de58..43ddf061 100644 --- a/tests/all/all.pro +++ b/tests/all/all.pro @@ -6,7 +6,6 @@ RESOURCES += tests.qrc SOURCES += \ dataform.cpp \ jingle.cpp \ - message.cpp \ register.cpp \ roster.cpp \ rpc.cpp \ @@ -19,7 +18,6 @@ SOURCES += \ HEADERS += \ dataform.h \ jingle.h \ - message.h \ register.h \ roster.h \ rpc.h \ diff --git a/tests/all/message.h b/tests/all/message.h deleted file mode 100644 index 08c71283..00000000 --- a/tests/all/message.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (C) 2008-2012 The QXmpp developers - * - * Authors: - * Jeremy Lainé - * Manjeet Dahiya - * - * Source: - * http://code.google.com/p/qxmpp - * - * This file is a part of QXmpp library. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - */ - -#include <QObject> - -class tst_QXmppMessage : public QObject -{ - Q_OBJECT - -private slots: - void testBasic_data(); - void testBasic(); - void testMessageAttention(); - void testMessageReceipt(); - void testDelay_data(); - void testDelay(); - void testExtendedAddresses(); - void testMucInvitation(); - void testState_data(); - void testState(); - void testXhtml(); -}; - diff --git a/tests/qxmppmessage/qxmppmessage.pro b/tests/qxmppmessage/qxmppmessage.pro new file mode 100644 index 00000000..3ab73fc9 --- /dev/null +++ b/tests/qxmppmessage/qxmppmessage.pro @@ -0,0 +1,3 @@ +include(../tests.pri) +TARGET = tst_qxmppmessage +SOURCES += tst_qxmppmessage.cpp diff --git a/tests/all/message.cpp b/tests/qxmppmessage/tst_qxmppmessage.cpp index fbdb5234..8e2caf85 100644 --- a/tests/all/message.cpp +++ b/tests/qxmppmessage/tst_qxmppmessage.cpp @@ -22,10 +22,28 @@ * */ +#include <QObject> #include "QXmppMessage.h" -#include "message.h" #include "util.h" +class tst_QXmppMessage : public QObject +{ + Q_OBJECT + +private slots: + void testBasic_data(); + void testBasic(); + void testMessageAttention(); + void testMessageReceipt(); + void testDelay_data(); + void testDelay(); + void testExtendedAddresses(); + void testMucInvitation(); + void testState_data(); + void testState(); + void testXhtml(); +}; + void tst_QXmppMessage::testBasic_data() { QTest::addColumn<QByteArray>("xml"); @@ -290,3 +308,6 @@ void tst_QXmppMessage::testXhtml() QCOMPARE(message.xhtml(), QLatin1String("<p style=\"font-weight:bold\">hi!</p>")); serializePacket(message, xml); } + +QTEST_MAIN(tst_QXmppMessage) +#include "tst_qxmppmessage.moc" diff --git a/tests/tests.pro b/tests/tests.pro index 238df105..8bfcef6c 100644 --- a/tests/tests.pro +++ b/tests/tests.pro @@ -1,2 +1,6 @@ TEMPLATE = subdirs -SUBDIRS = all qxmppiq qxmpppresence +SUBDIRS = \ + all \ + qxmppiq \ + qxmppmessage \ + qxmpppresence |
