Skip to content
This repository was archived by the owner on Jan 16, 2026. It is now read-only.
This repository was archived by the owner on Jan 16, 2026. It is now read-only.

configurations in order to accept User_Agent #595

@RaduRogoz

Description

@RaduRogoz

In order to test on mobile, i need to send the user agent as an option, when chrome starts.

Pull requests which are referring to this issue are:
#594 - Modifying configurations in order to accept User_Agent
#563 - add support for setting user agent and other selenium options

Reporting a problem? Please describe the issue above, and complete the following checklist so that we can help you more quickly.

Issue checklist:

  • I have validated my config file against YAML Validator to make sure it is valid YAML.

  • I have run the wraith info command and pasted the output below:

DEBUG: #################################################
DEBUG:   Command run:        info
DEBUG:   Wraith version:     4.2.3
DEBUG:   Ruby version:       ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-darwin17]
DEBUG:   ImageMagick:        Version: ImageMagick 7.0.8-14 Q16 x86_64 2018-10-25 https://imagemagick.org
DEBUG:   PhantomJS version:  2.1.1
DEBUG:   chromedriver version:  ChromeDriver 2.43.600229 (3fae4d0cda5334b4f533bede5a4787f7b832d052)
DEBUG:   CasperJS version:   Couldn't find nor compute phantom.casperPath, exiting.
DEBUG: #################################################
  • I have run the command in verbose mode (by adding verbose: true to my config) and pasted the output below:
 bundle exec wraith history spec/configs/mobile.yaml 
DEBUG: #################################################
DEBUG:   Command run:        history spec/configs/mobile.yaml
DEBUG:   Wraith version:     4.2.3
DEBUG:   Ruby version:       ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-darwin17]
DEBUG:   ImageMagick:        Version: ImageMagick 7.0.8-14 Q16 x86_64 2018-10-25 https://imagemagick.org
DEBUG:   PhantomJS version:  2.1.1
DEBUG:   chromedriver version:  ChromeDriver 2.43.600229 (3fae4d0cda5334b4f533bede5a4787f7b832d052)
DEBUG:   CasperJS version:   Couldn't find nor compute phantom.casperPath, exiting.
DEBUG: #################################################
Config validated. No serious issues found.
Creating Folders
SAVING IMAGES
  • I have pasted the contents of my config file below:
#Headless browser option
browser:
  # slimerjs: "slimerjs"
  chrome: chrome
selenium_options:
  - "--user-agent=Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25"

#If you want to have multiple snapping files, set the file name here
# snap_file: "app.js"s

# Type the name of the directory that shots will be stored in
directory: 'shots/mustang_mobile'
history_dir: "wraith_history/mobile"

# Add only 2 domains, key will act as a label
domains:
  url: "http://localhost:3001"


# Type screen widths below, here are a couple of examples
screen_widths:
  - 320
  - 756


before_capture: './spec/js/wait--chrome.js'

#Type page URL paths below, here are a couple of examples
paths:
  Home: /

#Amount of fuzz ImageMagick will use
fuzz: '20%'

#Set the number of days to keep the site spider file
spider_days:
  - 10

highlight_color: red

verbose: true

#Choose how results are displayed, by default alphanumeric. Different screen widths are always grouped.
#alphanumeric - all paths (with, and without, a difference) are shown, sorted by path
#diffs_first - all paths (with, and without, a difference) are shown, sorted by difference size (largest first)
#diffs_only - only paths with a difference are shown, sorted by difference size (largest first)
mode: diffs_first

threshold: 5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions