mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2025-09-09 10:19:41 +02:00
Improve message of XMPPErrorException
by including the XMPP entity which send the XMPP error reply to us. Also cleanup the no longer used constructors.
This commit is contained in:
parent
9165e818d9
commit
d976434bb3
7 changed files with 65 additions and 57 deletions
|
@ -35,6 +35,7 @@ import org.igniterealtime.smack.inttest.SmackIntegrationTestFramework.TestRunRes
|
|||
import org.jivesoftware.smack.SmackException;
|
||||
import org.jivesoftware.smack.XMPPException;
|
||||
import org.jivesoftware.smack.XMPPException.XMPPErrorException;
|
||||
import org.jivesoftware.smack.packet.Message;
|
||||
import org.jivesoftware.smack.packet.XMPPError;
|
||||
import org.junit.AfterClass;
|
||||
import org.junit.BeforeClass;
|
||||
|
@ -97,8 +98,9 @@ public class SmackIntegrationTestFrameworkUnitTest {
|
|||
|
||||
@SmackIntegrationTest
|
||||
public void throwRuntimeExceptionTest() throws XMPPErrorException {
|
||||
throw new XMPPException.XMPPErrorException(
|
||||
XMPPError.from(XMPPError.Condition.bad_request, DESCRIPTIVE_TEXT));
|
||||
Message message = new Message();
|
||||
throw new XMPPException.XMPPErrorException(message,
|
||||
XMPPError.from(XMPPError.Condition.bad_request, DESCRIPTIVE_TEXT).build());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue