@Test public void testJsonMarshalling() throws Exception { JsonMessage message = buildJsonMessage(internetExplorer()); processor.process(message.getDesiredCapabilities()); String proxyType = (String) new JSONObject(message.toJson()) .getJSONObject("desiredCapabilities") .getJSONObject("proxy") .get("proxyType"); assertThat(proxyType, is(equalTo(DIRECT.name()))); }
@Override public void process(JsonCapabilities caps) { caps.any().put("ie.ensureCleanSession", true); caps.any().put("ie.usePerProcessProxy", true); if (!caps.any().containsKey("proxy")) { Proxy proxy = new Proxy(); proxy.setProxyType("DIRECT"); caps.any().put("proxy", proxy); } }
IECapabilityProcessor implements CapabilityProcessor { @Override public void process(JsonCapabilities caps) { caps.any().put("ie.ensureCleanSession", true); caps.any().put("ie.usePerProcessProxy", true); if (!caps.any().containsKey("proxy")) { Proxy proxy = new Proxy(); proxy.setProxyType("DIRECT"); caps.any().put("proxy", proxy); } } }
IECapabilityProcessor implements CapabilityProcessor { @Override public void process(JsonCapabilities caps) { caps.any().put("ie.ensureCleanSession", true); caps.any().put("ie.usePerProcessProxy", true); if (!caps.any().containsKey("proxy")) { Proxy proxy = new Proxy(); proxy.setProxyType("DIRECT"); caps.any().put("proxy", proxy); } }  }
IECapabilityProcessor implements CapabilityProcessor { @Override public void process(JsonCapabilities caps) { caps.any().put("ie.ensureCleanSession", true); caps.any().put("ie.usePerProcessProxy", true); if (!caps.any().containsKey("proxy")) { Proxy proxy = new Proxy(); proxy.setProxyType("DIRECT"); caps.any().put("proxy", proxy); } }  @Override boolean accept(JsonCapabilities caps); @Override void process(JsonCapabilities caps); }
IECapabilityProcessor implements CapabilityProcessor { @Override public void process(JsonCapabilities caps) { caps.any().put("ie.ensureCleanSession", true); caps.any().put("ie.usePerProcessProxy", true); if (!caps.any().containsKey("proxy")) { Proxy proxy = new Proxy(); proxy.setProxyType("DIRECT"); caps.any().put("proxy", proxy); } }  @Override boolean accept(JsonCapabilities caps); @Override void process(JsonCapabilities caps);  }