List of usage examples for org.openqa.selenium ImmutableCapabilities ImmutableCapabilities
public ImmutableCapabilities(String k1, Object v1, String k2, Object v2, String k3, Object v3, String k4,
Object v4, String k5, Object v5)
From source file:org.openqa.grid.selenium.node.FirefoxMutatorTest.java
License:Apache License
@Test public void shouldInjectIfConfigUuidMatches() { ImmutableCapabilities defaultConfigWithUuid = new ImmutableCapabilities("browserName", "firefox", BINARY, "binary", "firefox_profile", "profile", MARIONETTE, true, GridNodeConfiguration.CONFIG_UUID_CAPABILITY, "123"); ImmutableCapabilities caps = new ImmutableCapabilities("browserName", "firefox", MARIONETTE, "cheese", GridNodeConfiguration.CONFIG_UUID_CAPABILITY, "123"); ImmutableCapabilities seen = new FirefoxMutator(defaultConfigWithUuid).apply(caps); assertEquals(true, seen.getCapability(MARIONETTE)); }
From source file:org.openqa.grid.selenium.node.FirefoxMutatorTest.java
License:Apache License
@Test public void shouldNotInjectIfConfigUuidDoesNotMatch() { ImmutableCapabilities defaultConfigWithUuid = new ImmutableCapabilities("browserName", "firefox", BINARY, "binary", "firefox_profile", "profile", MARIONETTE, true, GridNodeConfiguration.CONFIG_UUID_CAPABILITY, "uuid"); ImmutableCapabilities caps = new ImmutableCapabilities("browserName", "firefox", MARIONETTE, "cheese", GridNodeConfiguration.CONFIG_UUID_CAPABILITY, "123"); ImmutableCapabilities seen = new FirefoxMutator(defaultConfigWithUuid).apply(caps); assertEquals("cheese", seen.getCapability(MARIONETTE)); }
From source file:org.openqa.grid.selenium.node.FirefoxMutatorTest.java
License:Apache License
@Test public void shouldNotInjectIfUuidIsPresentInConfigOnly() { ImmutableCapabilities defaultConfigWithUuid = new ImmutableCapabilities("browserName", "firefox", BINARY, "binary", "firefox_profile", "profile", MARIONETTE, true, GridNodeConfiguration.CONFIG_UUID_CAPABILITY, "uuid"); ImmutableCapabilities caps = new ImmutableCapabilities("browserName", "firefox", MARIONETTE, "cheese"); ImmutableCapabilities seen = new FirefoxMutator(defaultConfigWithUuid).apply(caps); assertEquals("cheese", seen.getCapability(MARIONETTE)); }