PtlCapabilities extends DesiredCapabilities { public String getPlatformVersion() { return toString(getCapability("platformVersion")); } PtlCapabilities(Map<String, ?> rawMap);  PtlCapabilities(Capabilities other); static List<PtlCapabilities[]> readCapabilities(); String getPlatformName(); String getPlatformVersion(); String getDeviceName();  }
@Test public void testGetPlatformVersion() throws Exception { Map<String, Object> map = new LinkedHashMap<String, Object>(); map.put("platformVersion", "hoge"); PtlCapabilities capabilities = new PtlCapabilities(map); assertThat(capabilities.getPlatformVersion(), is("hoge")); }