Web Feed

Given that the WebDriver instance is completely managed by Ekam, you must be wondering where & how to provide options to supply while starting the driver instance

Web Feed

Web Feed is a template for creating WebDriver Instance with options specific to a browser.

  • desiredCapabilities: Read more about this here.

  • arguments: Chrome, Firefox

  • preferences: List of preferences like download directory. Refer to browser documentation for supported preferences.

  • extensions: List of extensions with their path (['/path/to/extension1', ‘/path/to/extension2’])

  • experimentalOptions: Experimental flags supported by the browser.

NOTE: You can create multiple WebFeeds like chrome.json, firefox.json, etc, or Use the same feed for all the browsers if a common configuration is used. Set property web.feed either in config or as system property to specify the WebFeed to be used.

Web Feed Location

src/test/resources/web/webfeed.json

Let’s give it a shot. Let’s execute the test in incognito & full-screen mode

Modify the webfeed.json as below specifying arguments “incognito” & “start-fullscreen:

{
  "desiredCapabilities": {
  },
  "arguments": [
    "incognito", "start-fullscreen"
  ],
  "preferences": {
  },
  "extensions": [
  ],
  "experimentalOptions": {
  }
}

Once we have updated the webfeed.json, let’s ask our config to refer to it. In this case, we are using default.properties

The default.properties file would like this now:

# Web Config

# Web url of web application under test
web.url:http://google.com

# Feed file having desiredCapabilities, arguments etc
web.feed:webfeed

Execute test. The test would trigger in incognito mode & in fullscreen