use of org.jivesoftware.smack.chat.ChatManagerListener in project Smack by igniterealtime.
the class ChatTest method chatManagerTest.
@SuppressWarnings("deprecation")
@SmackIntegrationTest
public void chatManagerTest() {
ChatManagerListener listener = new ChatManagerListener() {
@Override
public void chatCreated(org.jivesoftware.smack.chat.Chat chat, boolean createdLocally) {
invoked = true;
}
};
try {
chatManagerOne.addChatListener(listener);
chatManagerOne.createChat(conTwo.getUser());
assertTrue("TestChatManagerListener wasn't invoked", invoked);
} finally {
chatManagerOne.removeChatListener(listener);
}
}
Aggregations