The Enter Key is simulated via a reflection hack (calls a method), STF 
does not use real keyboard inputs (set to a SWTBO mock keyboard,
please do not use shortcuts !).

BR,
Stefan

Am 24.09.2012 17:18, schrieb Michael:
> Dear developers,
>
>
> Im trying to implement a STF test for a chat, but a problem occured and
> I'd like you to help me.
>
> The symptom:
> The message text is entered into an inputfield as expected but the enter
> key is not pressed.
> I haven't found any occasion of a similar situation in saros except one:
> The the multi user chat circumvented the problem by sending a message
> without a real enter key event.
>
> The enter key functionality on an inputfield ("chatInput" of type
> SarosSWTBotChatInput, see test/../Chatroom.java) just does not work, at
> least not in a stable way.
>
> I tried:
> -    generating a new Robot() that presses enter:
> robot.keyPress(KeyEvent.VK_ENTER);
>        This worked occasionally, no matter if or if not inside of a
> runnable for Utils.runSafeSWTSync.
>        Also it only worked when run without debugging.
>
> I also tried:
> -    changing the KeyboardStrategy (AWT-,SWT-,Mock-)
>
> -    chatInput.typeText(message + "\n\r") and settext( ... );
>
> -    chatInput.pressShortcut(SWT.CR, SWT.LF);
>        chatInput.pressShortcut(SWT.NONE, SWT.LF);
>        chatInput.pressShortcut(SWT.NONE, SWT.CR);
>
> -    circumventing the problem without pressing the enter key is not an
> option
>
>
> Thank you for any input
>
> Michael
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Dpp-devel mailing list
> Dpp-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dpp-devel


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Dpp-devel mailing list
Dpp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dpp-devel

Reply via email to