Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Calabash for testing. There's a facebook login button in my app, when I click on it, a form is to be opened. I want to get the url of the current webview because it is easy for querying. But command query ("webview","url") doesn't return the correct url. Please help me. Many thanks.

Here is a screenshot :-

share|improve this question
what does query("webview") return? – amazpyel Jun 11 '14 at 13:38

Try query("customWebView", "url").

I've seen the same issue when customWebView was implemented instead of simple webView.

share|improve this answer
Both queries do not return URL. Please reference the screenshot, I have updated for it. – Cuong Nguyen Jun 11 '14 at 4:56
Please tell: What calabash-android version do you use? You can get it with gem list calabash-android command. – Dmitry Cheremushkin Jun 11 '14 at 21:23
Hi Dmitry. My version: 0.4.22.pre04, 0.4.21 – Cuong Nguyen Jun 12 '14 at 7:41

@Cuong - I can suggest to use appropriate classes -

Standard Android WebViews:


Crosswalk WebViews:


Titanium WebViews:


PhoneGap / Cordova WebViews:



query('webView')     //UIWebView
query('UIWebView')   //UIWebView


query('WKWebView')   //WKWebView

Hope it helps !

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.