I've seen this kind of thing done sometimes by very careful crafting of 
sendkeys but it usually results in a very brittle script.

If you are testing some kind of web based editor control, you should be 
asking yourself a few questions:

1) am I really just testing the browser if I do this?   Selection, copy, 
pasting to replace a selection, etc are all basic browser functionality in 
any text-field or edit box.  So to some extent this could constitute 
testing the browser, which unless you work for google, mozilla, or MS may 
not be a good use of your time.
2) Am I really just testing some third party code library if I do this?  If 
you are using a third party edit control, then you could well be crossing 
over into testing someone else's code library.. again this might be a poor 
use of resources.  (and if your devs are rolling their own rich editor? for 
ghods sake why when there are a bunch already out there that could be 
re-used.. that could be a bad use of *their* time)   In the case of 
something like that your biggest concern is 'did we integrate that code 
properly and invoke it with the right options?  In that case a fast manual 
smoketest may be all you need in most cases(since that library is likely to 
remain very static), or a slighty deeper test if/when you update the 
version of that library to a new one, just to be sure it's still properly 
configured in your code etc.


On Tuesday, June 12, 2012 3:42:29 PM UTC-7, andrey wrote:
>
> Hi Guys 
>
> Is there a way to simulate a mouse select a piece of text from a div 
> container 
>
> This is an example of what I want to achieve 
>
> http://cl.ly/393k0M1R1u460K2s033A 
>
>
> I have been looking at 
>
> http://wiki.openqa.org/display/WTR/Right+Click+an+Element 
>
> but I want it to test on a Chrome, FF on Mac, that example seems to 
> need the Windows API, which I assume only works under windows 
>
> Thanks for your help guys

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

Reply via email to