GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — wd/doc/jsonwire-mobile.md at master · admc/wd

Expand file tree

/

jsonwire-mobile.md

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
78 lines (59 loc) · 2.54 KB
/

jsonwire-mobile.md

Copy path

File metadata and controls

78 lines (59 loc) · 2.54 KB
Raw
Copy raw file
Download raw file
Outline
Edit and raw actions

Mobile JsonWire Protocol Methods

Wd.js is incrementally implementing the Mobile JsonWire Protocol Spec

  • read the draft
  • Look for mjsonWire in the api doc.

-ios uiautomation Locator Strategy

Find elements in iOS applications using the UIAutomation Javascript API

eg:

wd.elementsByIosUIAutomation('.tableViews()[0].cells()', function(err, el){
  el.elementByIosUIAutomation('.elements()["UICatalog"]', function(err, el){
    el.getAttribute('name', function(err, name){
      console.log(name);
    });
  });
});

-ios class chain Locator Strategy

Find elements in iOS applications using the WebDriverAgent Class Chain API

eg:

wd.elementsByIosClassChain('XCUIElementTypeWindow/XCUIElementTypeAny[`value == "bla1" OR label == "bla2"`]', function(err, el){
  el.getAttribute('name', function(err, name){
    console.log(name);
  });
});

-ios predicate Locator Strategy

Find elements in iOS applications using the WebDriverAgent Predicate API

eg:

wd.elementsByIosPredicateString('type IN {`XCUIElementTypeIcon`,`XCUIElementTypeImage`} AND visible == 1', function(err, el){
  el.getAttribute('name', function(err, name){
    console.log(name);
  });
});

-android uiautomator Locator Strategy

Find elements in android applications using the UiSelector Class

eg:

wd.elementsByAndroidUIAutomator('new UiSelector().clickable(true)', function(err, els){
  console.log("number of clickable elements:", els.length);
});

-android datamatcher Locator Strategy

Find elements in android applications using Espresso Data Matcher

e.g.:

wd.elementsByAndroidDataMatcher(JSON.stringify({name: "hasEntry", args: ["title", "ViewTitle"]})', function(err, els){
  console.log("number of clickable elements:", els.length);
});

accessibility id

Find elements by whatever identifier is used by the platforms Accessibility framework.

eg:

wd.elementByAccessibilityId("Submit", function(err, el){
  el.click();
});
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.