aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2012-09-27 15:12:16 +0200
committerJeremy Lainé <jeremy.laine@m4x.org>2012-09-27 15:12:16 +0200
commit57532909b5970645ca9fdd5f9a69bd3258d8a914 (patch)
tree4b67ae7fa40c80bae03a51f54cf7bb9115c5942c /tests
parent71dacec7ebf3731927559e57c402520bfbf88500 (diff)
downloadqxmpp-57532909b5970645ca9fdd5f9a69bd3258d8a914.tar.gz
split QXmppPresence tests out
Diffstat (limited to 'tests')
-rw-r--r--tests/all/all.pro2
-rw-r--r--tests/all/presence.h40
-rw-r--r--tests/all/tests.cpp4
-rw-r--r--tests/qxmpppresence/tst_qxmpppresence.cpp (renamed from tests/all/presence.cpp)19
4 files changed, 18 insertions, 47 deletions
diff --git a/tests/all/all.pro b/tests/all/all.pro
index 32a8251a..9141de58 100644
--- a/tests/all/all.pro
+++ b/tests/all/all.pro
@@ -7,7 +7,6 @@ SOURCES += \
dataform.cpp \
jingle.cpp \
message.cpp \
- presence.cpp \
register.cpp \
roster.cpp \
rpc.cpp \
@@ -21,7 +20,6 @@ HEADERS += \
dataform.h \
jingle.h \
message.h \
- presence.h \
register.h \
roster.h \
rpc.h \
diff --git a/tests/all/presence.h b/tests/all/presence.h
deleted file mode 100644
index 74bd7ee8..00000000
--- a/tests/all/presence.h
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2008-2012 The QXmpp developers
- *
- * Authors:
- * Olivier Goffart
- * Jeremy Lainé
- *
- * 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_QXmppPresence : public QObject
-{
- Q_OBJECT
-
-private slots:
- void testPresence();
- void testPresence_data();
- void testPresenceWithCapability();
- void testPresenceWithExtendedAddresses();
- void testPresenceWithMucItem();
- void testPresenceWithMucPassword();
- void testPresenceWithMucSupport();
-};
-
diff --git a/tests/all/tests.cpp b/tests/all/tests.cpp
index 0741c84e..82f007f5 100644
--- a/tests/all/tests.cpp
+++ b/tests/all/tests.cpp
@@ -48,7 +48,6 @@
#include "dataform.h"
#include "jingle.h"
#include "message.h"
-#include "presence.h"
#include "register.h"
#include "roster.h"
#include "rpc.h"
@@ -904,9 +903,6 @@ int main(int argc, char *argv[])
tst_QXmppMessage testMessage;
errors += QTest::qExec(&testMessage);
- tst_QXmppPresence testPresence;
- errors += QTest::qExec(&testPresence);
-
TestPubSub testPubSub;
errors += QTest::qExec(&testPubSub);
diff --git a/tests/all/presence.cpp b/tests/qxmpppresence/tst_qxmpppresence.cpp
index c2762622..4cbe8caa 100644
--- a/tests/all/presence.cpp
+++ b/tests/qxmpppresence/tst_qxmpppresence.cpp
@@ -22,11 +22,26 @@
*
*/
+#include <QObject>
+
#include "QXmppPresence.h"
-#include "presence.h"
#include "util.h"
+class tst_QXmppPresence : public QObject
+{
+ Q_OBJECT
+
+private slots:
+ void testPresence();
+ void testPresence_data();
+ void testPresenceWithCapability();
+ void testPresenceWithExtendedAddresses();
+ void testPresenceWithMucItem();
+ void testPresenceWithMucPassword();
+ void testPresenceWithMucSupport();
+};
+
void tst_QXmppPresence::testPresence_data()
{
QXmppPresence foo;
@@ -221,3 +236,5 @@ void tst_QXmppPresence::testPresenceWithMucSupport()
serializePacket(presence, xml);
}
+QTEST_MAIN(tst_QXmppPresence)
+#include "tst_qxmpppresence.moc"