mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-26 22:12:05 +01:00
Added a timeout for retrieving messages. Thus preventing an unrecoverable situation.
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2446 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
cb27d4f0de
commit
fd3f88480f
1 changed files with 2 additions and 2 deletions
|
@ -125,7 +125,7 @@ public class FormTest extends SmackTestCase {
|
||||||
chat.sendMessage(msg);
|
chat.sendMessage(msg);
|
||||||
|
|
||||||
// Get the message with the form to fill out
|
// Get the message with the form to fill out
|
||||||
Message msg2 = chat2.nextMessage();
|
Message msg2 = chat2.nextMessage(2000);
|
||||||
// Retrieve the form to fill out
|
// Retrieve the form to fill out
|
||||||
Form formToRespond = Form.getFormFrom(msg2);
|
Form formToRespond = Form.getFormFrom(msg2);
|
||||||
assertNotNull(formToRespond);
|
assertNotNull(formToRespond);
|
||||||
|
@ -156,7 +156,7 @@ public class FormTest extends SmackTestCase {
|
||||||
chat2.sendMessage(msg2);
|
chat2.sendMessage(msg2);
|
||||||
|
|
||||||
// Get the message with the completed form
|
// Get the message with the completed form
|
||||||
Message msg3 = chat.nextMessage();
|
Message msg3 = chat.nextMessage(2000);
|
||||||
// Retrieve the completed form
|
// Retrieve the completed form
|
||||||
completedForm = Form.getFormFrom(msg3);
|
completedForm = Form.getFormFrom(msg3);
|
||||||
assertNotNull(completedForm);
|
assertNotNull(completedForm);
|
||||||
|
|
Loading…
Reference in a new issue