Package org.igniterealtime.smack.inttest
Class AbstractSmackIntegrationTest
java.lang.Object
org.igniterealtime.smack.inttest.AbstractSmackIntTest
org.igniterealtime.smack.inttest.AbstractSmackIntegrationTest
- Direct Known Subclasses:
AbstractChatIntegrationTest
,AbstractMultiUserChatIntegrationTest
,AbstractOmemoIntegrationTest
,AbstractOpenPgpIntegrationTest
,AdHocCommandIntegrationTest
,ChatStateIntegrationTest
,ChatTest
,EntityCapsTest
,FileTransferIntegrationTest
,FormTest
,GeolocationIntegrationTest
,HttpFileUploadIntegrationTest
,IoTControlIntegrationTest
,IoTDataIntegrationTest
,IoTDiscoveryIntegrationTest
,MamIntegrationTest
,MoodIntegrationTest
,PingIntegrationTest
,PubSubIntegrationTest
,RosterIntegrationTest
,SoftwareInfoIntegrationTest
,UserTuneIntegrationTest
,VersionIntegrationTest
-
Nested Class Summary
Nested classes/interfaces inherited from class org.igniterealtime.smack.inttest.AbstractSmackIntTest
AbstractSmackIntTest.Condition
-
Field Summary
Modifier and TypeFieldDescriptionprotected final org.jivesoftware.smack.XMPPConnection
An alias for the first connectionconOne
.protected final List<org.jivesoftware.smack.XMPPConnection>
protected final org.jivesoftware.smack.XMPPConnection
The first connection.protected final org.jivesoftware.smack.XMPPConnection
The third connection.protected final org.jivesoftware.smack.XMPPConnection
The second connection.Fields inherited from class org.igniterealtime.smack.inttest.AbstractSmackIntTest
INSECURE_RANDOM, LOGGER, sinttestConfiguration, testRunId, timeout
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
performActionAndWaitForPresence
(org.jivesoftware.smack.XMPPConnection conA, org.jivesoftware.smack.XMPPConnection conB, org.jivesoftware.smack.util.Async.ThrowingRunnable action) Perform action and wait until conA observes a presence form conB.Methods inherited from class org.igniterealtime.smack.inttest.AbstractSmackIntTest
assertResult, assertResult, assertResult, assertResult, createNewTempFile, getHttpUrlConnectionFor, performActionAndWaitUntilStanzaReceived, waitUntilTrue
-
Field Details
-
conOne
protected final org.jivesoftware.smack.XMPPConnection conOneThe first connection. -
conTwo
protected final org.jivesoftware.smack.XMPPConnection conTwoThe second connection. -
conThree
protected final org.jivesoftware.smack.XMPPConnection conThreeThe third connection. -
connection
protected final org.jivesoftware.smack.XMPPConnection connectionAn alias for the first connectionconOne
. -
connections
-
-
Constructor Details
-
AbstractSmackIntegrationTest
-
-
Method Details
-
performActionAndWaitForPresence
protected void performActionAndWaitForPresence(org.jivesoftware.smack.XMPPConnection conA, org.jivesoftware.smack.XMPPConnection conB, org.jivesoftware.smack.util.Async.ThrowingRunnable action) throws Exception Perform action and wait until conA observes a presence form conB.This method is usually used so that 'action' performs an operation that changes one entities features/nodes/capabilities, and we want to check that another connection is able to observe this change, and use that new "thing" that was added to the connection.
Note that this method is a workaround at best and not reliable. Because it is not guaranteed that any XEP-0030 related manager, e.g. EntityCapsManager, already processed the presence when this method returns.
TODO: Come up with a better solution.- Parameters:
conA
- the connection to observe the presence on.conB
- the connection sending the presenceaction
- the action to perform.- Throws:
Exception
- in case of an exception.
-