Thanks for the reply John...I've managed to fix the issue.

On Wednesday, July 10, 2013, John Fitisoff wrote:

> A couple of seconds seems like a long time. Maybe try the action builder
> 'release' action instead of firing the event? Maybe some javascript event
> isn't occurring at the right time? One thing that really helps me is to use
> pry to stop the test right at the point that the problem is occurring
> (maybe you're already doing something like that). Then it's a lot easier to
> see what's going on. You can just install pry and then insert binding.pry
> at the point where you want the test to halt. Then type exit to continue
> execution.
>
>
>   ------------------------------
>  *From:* watir webdriver <[email protected] <javascript:_e({},
> 'cvml', '[email protected]');>>
> *To:* [email protected] <javascript:_e({}, 'cvml',
> '[email protected]');>
> *Sent:* Wednesday, July 10, 2013 3:43 AM
> *Subject:* [wtr-general] Re: [Watir-webdriver] - Drag and drop using
> watir webdriver
>
> Thanks for your reply...with this code I can see the drag and drop but
> after couple of seconds the dropped element is getting disappeared...but
> the scenario is passed successfully...Although it didn't work as expected
> when I checked manually by visiting the webpage.Any one can help me with
> this ?
>
> my_element = @browser.span(:text => "Abandoned Basket")
> target = @browser.div(:class => "droparea ui-droppable ui-sortable")
> target = @browser.div(:id => "0")
> my_element.fire_event("onmousedown")
> @browser.driver.action.click_and_hold(my_element.wd).perform
> sleep 15
> @browser.driver.action.move_to(target.wd).perform
> sleep 15
> my_element.fire_event("onmouseup")
> end
>
> Your help is much more appreciated.
>
>
> On Wednesday, July 3, 2013 2:53:28 PM UTC+1, watir webdriver wrote:
>
> Hi there,
>
> I'm trying to drag and drop an element in webpage through the below code:
>
> Step def:
> When(/^I drag and drop Basket rule to the position slot$/) do
> @browser.span(:class => "draggable ui-draggable").drag_and_drop_
> on(@browser.div(:class => "droparea ui-droppable ui-sortable"))
> end
>
> *The scenario is passing but on the webpage its just high lighting the
> draggable element.*(drop is not working)
>
> *HTML code for draggable code*:
> <tr>
> <td>
> <span class="draggable ui-draggable" full="Basket" ai d="BASKET"> Basket</
> span>
> </td>
> <tr>
>
>
> *HTML code for droppable code:*
> <div id="0" class="droparea ui-droppable ui-sortable">
>
> Anyone can help me with this issue ?
>
> Thanks in-advance.
>
>
> --
> --
> Before posting, please read http://watir.com/support. In short: search
> before you ask, be nice.
>
> [email protected] <javascript:_e({}, 'cvml',
> '[email protected]');>
> http://groups.google.com/group/watir-general
> [email protected] <javascript:_e({}, 'cvml',
> 'watir-general%[email protected]');>
>
> ---
> You received this message because you are subscribed to the Google Groups
> "Watir General" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected] <javascript:_e({},
> 'cvml', 'watir-general%[email protected]');>.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
>
>   --
> --
> Before posting, please read http://watir.com/support. In short: search
> before you ask, be nice.
>
> [email protected] <javascript:_e({}, 'cvml',
> '[email protected]');>
> http://groups.google.com/group/watir-general
> [email protected] <javascript:_e({}, 'cvml',
> 'watir-general%[email protected]');>
>
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "Watir General" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/watir-general/mrHJU9iGIqI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected] <javascript:_e({}, 'cvml',
> 'watir-general%[email protected]');>.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
-- 
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]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to