diff options
Diffstat (limited to 'Swiften/Avatars/UnitTest')
-rw-r--r-- | Swiften/Avatars/UnitTest/VCardAvatarManagerTest.cpp | 3 | ||||
-rw-r--r-- | Swiften/Avatars/UnitTest/VCardUpdateAvatarManagerTest.cpp | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/Swiften/Avatars/UnitTest/VCardAvatarManagerTest.cpp b/Swiften/Avatars/UnitTest/VCardAvatarManagerTest.cpp index 23b4169..1c23821 100644 --- a/Swiften/Avatars/UnitTest/VCardAvatarManagerTest.cpp +++ b/Swiften/Avatars/UnitTest/VCardAvatarManagerTest.cpp @@ -10,6 +10,7 @@ #include <cppunit/extensions/TestFactoryRegistry.h> #include <boost/bind.hpp> +#include <QA/Checker/IO.h> #include <Swiften/Elements/VCard.h> #include <Swiften/Avatars/VCardAvatarManager.h> #include <Swiften/Avatars/AvatarMemoryStorage.h> @@ -42,7 +43,7 @@ class VCardAvatarManagerTest : public CppUnit::TestFixture { avatarStorage = new AvatarMemoryStorage(); vcardStorage = new VCardMemoryStorage(); vcardManager = new VCardManager(ownJID, iqRouter, vcardStorage); - avatar1 = ByteArray("abcdefg"); + avatar1 = createByteArray("abcdefg"); avatar1Hash = Hexify::hexify(SHA1::getHash(avatar1)); user1 = JID("user1@bar.com/bla"); user2 = JID("user2@foo.com/baz"); diff --git a/Swiften/Avatars/UnitTest/VCardUpdateAvatarManagerTest.cpp b/Swiften/Avatars/UnitTest/VCardUpdateAvatarManagerTest.cpp index 2a3b3fd..966e4ef 100644 --- a/Swiften/Avatars/UnitTest/VCardUpdateAvatarManagerTest.cpp +++ b/Swiften/Avatars/UnitTest/VCardUpdateAvatarManagerTest.cpp @@ -10,6 +10,7 @@ #include <cppunit/extensions/TestFactoryRegistry.h> #include <boost/bind.hpp> +#include <QA/Checker/IO.h> #include <Swiften/Elements/VCardUpdate.h> #include <Swiften/Avatars/VCardUpdateAvatarManager.h> #include <Swiften/Avatars/AvatarMemoryStorage.h> @@ -44,7 +45,7 @@ class VCardUpdateAvatarManagerTest : public CppUnit::TestFixture { avatarStorage = new AvatarMemoryStorage(); vcardStorage = new VCardMemoryStorage(); vcardManager = new VCardManager(ownJID, iqRouter, vcardStorage); - avatar1 = ByteArray("abcdefg"); + avatar1 = createByteArray("abcdefg"); avatar1Hash = Hexify::hexify(SHA1::getHash(avatar1)); user1 = JID("user1@bar.com/bla"); user2 = JID("user2@foo.com/baz"); @@ -163,7 +164,7 @@ class VCardUpdateAvatarManagerTest : public CppUnit::TestFixture { IQ::ref createVCardResult(const ByteArray& avatar) { VCard::ref vcard(new VCard()); - if (!avatar.isEmpty()) { + if (!avatar.empty()) { vcard->setPhoto(avatar); } return IQ::createResult(JID("baz@fum.com"), stanzaChannel->sentStanzas[0]->getID(), vcard); |