void testAddFromNonAccount() {
			boost::shared_ptr<XMPPRosterController> testling(createController());

			boost::shared_ptr<RosterPayload> payload(new RosterPayload());
			payload->addItem(RosterItemPayload(jid1_, "Bob", RosterItemPayload::Both));
			IQ::ref request = IQ::createRequest(IQ::Set, JID(), "eou", payload);
			request->setFrom(jid2_);
			channel_->onIQReceived(request);

			CPPUNIT_ASSERT_EQUAL(None, handler_->getLastEvent());
		}
Пример #2
0
 IQ::ref createIBBRequest(IBB::ref ibb, const JID& from, const std::string& id) {
     IQ::ref request = IQ::createRequest(IQ::Set, JID("[email protected]/dum"), id, ibb);
     request->setFrom(from);
     return request;
 }