Skip to content

Headless mode

Headless mode is used to run test in one command

  • Show all params in headless mode: test --headless –h
  • Example: test --headless -pj "D:\Project\aka-test\akatest" -tid dac80b48-03dc-4f23-b993-7acaadcc48eb -zip "D:\Project\ach" -pf Chrome

Note: You can choose to run by -tid or -tp (testcase or test suite or test flex)

The following tables show the details for all params in headless mode

Headless mode params

Short Long Description Mandatory Has argument Example
-headless --headless Run headless mode Yes No
-tid --testId Test file ID Yes Yes -tid dac80b48-03dc-4f23-b993-7acaadcc48eb
-tp --testpath Test with relative path Yes Yes -tp "/test-cases/Test.tc"
-zip --zipPath Folder to save all file for zipping report after run test No Yes -zip "D:\Project\ach"
-pj --project Project path Yes Yes -pj "D:\Project\aka-test\akatest"
-pf --profile Run test by profile Yes Yes -pf Chrome

Note:

  • User can only user -tid or -tp in the same command
  • Setting file has info of the following params: -phost, -pport , -policy, -puser, -ppass, -chromedriver, -edgedriver, -geckodriver, -zip

  • Example of setting file:

{
  "workspace": {
    "webrecord.addwait": "true"
  },
  "setting": {
    "step.delay": "300",
    "computer.name": "CPP00088550B",
    "http.proxyHost": "ExampleProxy",
    "appium.execute": "C:\\Users\userName\AppData\\Roaming\\npm\\node_modules\\appium\\build\\lib\\main.js",
    "webdriver.chrome.driver": "",
    "webdriver.edge.driver": "",
    "webdriver.gecko.driver": "",
    "winappdriver.execute": "C:\\Program Files\\Windows Application Driver\\WinAppDriver.exe",
    "http.proxyUser": "ExampleAccount",
    "http.proxyPassword": "ExamplePass",
    "webdriver.ie.driver": "",
    "computer.id": "vmvgt",
    "jmeter.home": "",
    "driver.stop.testcase": "true",
    "http.proxyPort": "8080"
  }
}