Class MessageEncryptionIntegrationTest


  • @SpecificationReference(document="XEP-0384")
    public class MessageEncryptionIntegrationTest
    extends AbstractTwoUsersOmemoIntegrationTest
    Simple OMEMO message encryption integration test. During this test Alice sends an encrypted message to Bob. Bob decrypts it and sends a response to Alice. It is checked whether the messages can be decrypted, and if used up pre-keys result in renewed bundles.
    • Constructor Detail

      • MessageEncryptionIntegrationTest

        public MessageEncryptionIntegrationTest​(SmackIntegrationTestEnvironment environment)
                                         throws org.jivesoftware.smack.XMPPException.XMPPErrorException,
                                                org.jivesoftware.smack.SmackException.NotConnectedException,
                                                java.lang.InterruptedException,
                                                org.jivesoftware.smack.SmackException.NoResponseException,
                                                TestNotPossibleException
        Throws:
        org.jivesoftware.smack.XMPPException.XMPPErrorException
        org.jivesoftware.smack.SmackException.NotConnectedException
        java.lang.InterruptedException
        org.jivesoftware.smack.SmackException.NoResponseException
        TestNotPossibleException
    • Method Detail

      • messageTest

        @SmackIntegrationTest
        public void messageTest()
                         throws java.lang.Exception
        This test checks whether the following actions are performed. Alice publishes bundle A1 Bob publishes bundle B1 Alice sends message to Bob (preKeyMessage) Bob publishes bundle B2 Alice still has A1 Bob responds to Alice (normal message) Alice still has A1 Bob still has B2
        Throws:
        java.lang.Exception - if an exception occurs.