Search in sources :

Example 1 with MockIdeaMessage

use of jetbrains.communicator.mock.MockIdeaMessage in project intellij-plugins by JetBrains.

the class UserTreeTest method testDeliverLocalMessage.

public void testDeliverLocalMessage() throws Exception {
    MockIdeaMessage message = new MockIdeaMessage();
    myLocalMessageDispatcher.addPendingMessage(myUser, message);
    MouseEvent mouseEvent = createMouseEvent();
    myUserTree.onClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    verifyMessageDelivery();
}
Also used : MouseEvent(java.awt.event.MouseEvent) MockIdeaMessage(jetbrains.communicator.mock.MockIdeaMessage)

Example 2 with MockIdeaMessage

use of jetbrains.communicator.mock.MockIdeaMessage in project intellij-plugins by JetBrains.

the class UserTreeTest method testDoubleClickEventsInQueue.

public void testDoubleClickEventsInQueue() throws Exception {
    MockIdeaMessage message = new MockIdeaMessage();
    myLocalMessageDispatcher.addPendingMessage(myUser, message);
    MouseEvent mouseEvent = createMouseEvent();
    myUserTree.onClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    myUserTree.onDblClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    verifyMessageDelivery();
}
Also used : MouseEvent(java.awt.event.MouseEvent) MockIdeaMessage(jetbrains.communicator.mock.MockIdeaMessage)

Example 3 with MockIdeaMessage

use of jetbrains.communicator.mock.MockIdeaMessage in project intellij-plugins by JetBrains.

the class UserTreeTest method testDoubleClick_AfterDelivery.

public void testDoubleClick_AfterDelivery() throws Exception {
    MockIdeaMessage message = new MockIdeaMessage();
    myLocalMessageDispatcher.addPendingMessage(myUser, message);
    MouseEvent mouseEvent = createMouseEvent();
    myUserTree.onClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    myUserTree.onDblClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    verifyMessageDelivery();
    myUserTree.onClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    myUserTree.onDblClick(myTreePath, myTreePath.getLastPathComponent(), mouseEvent);
    assertTrue("Should invoke send message dialog when nothing to deliver", mySendMessageInvoked);
}
Also used : MouseEvent(java.awt.event.MouseEvent) MockIdeaMessage(jetbrains.communicator.mock.MockIdeaMessage)

Aggregations

MouseEvent (java.awt.event.MouseEvent)3 MockIdeaMessage (jetbrains.communicator.mock.MockIdeaMessage)3