Hi Mike,
from this its difficult to say exactly what happens, but my guess is that
there is a concurrency problem.
Try waiting until the button is clickable. Or until the mentioned element
is gone
static content = {
button { $('button.ui-btn.ui-btn-secondary') }
div { $('div.ui-backdrop.visible.ng-scope') }
}
def clickbutton() {
waitFor { !div.displayed }
button.click()
}
Regards
Yori
Am Mittwoch, 11. Januar 2017 02:18:54 UTC+1 schrieb Mike Wang:
>
> HI Yori
>
> Thanks for your reply,but below exception poppued up:
> Caught: org.openqa.selenium.WebDriverException: Element is not clickable
> at point (720, 342). Other element would receive the click: <div
> style="opacity: 0.8; z-index: 5000;" class="ui-backdrop visible
> ng-scope"></div>
> Command duration or timeout: 61 milliseconds
>
> On Tue, Jan 10, 2017 at 6:37 PM, Yori Kurita <[email protected]
> <javascript:>> wrote:
>
>> Hi,
>>
>> try : button { $('button.ui-btn.ui-btn-secondary') }
>>
>> Am Dienstag, 10. Januar 2017 10:26:03 UTC+1 schrieb
>> [email protected]:
>>>
>>> HI Everyone,
>>>
>>> I am new to groovy geb,and for below HTML code,who can tell me how to
>>> locate the button element?seems that it uses angular js.I tried different
>>> way,can not click this button.
>>>
>>> <button class="ui-btn ui-btn-secondary" ng-click="
>>> uiAside.show('add-invoice-aside')"> 发票录入 </button>
>>>
>> --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Geb User Mailing List" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/geb-user/SO4pXsKUcIo/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> [email protected] <javascript:>.
>> To post to this group, send email to [email protected]
>> <javascript:>.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/geb-user/9d81e9fe-d1fd-4d52-955e-fb6e3f16a3e1%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/geb-user/9d81e9fe-d1fd-4d52-955e-fb6e3f16a3e1%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Mike Wang
> QA Engineer
>
> Cell: *+86 18550044188*
> Skype: *[email protected] <javascript:>*
>
> BAIWANG TRADESHIFT
> All your suppliers. All in one place
> tradeshift.com ׀ tradeshift blog
>
--
You received this message because you are subscribed to the Google Groups "Geb
User Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/geb-user/ddb06a54-3e35-4d1d-9a16-7d853f7ba2ea%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.