tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

config.md (6244B)


Configuration - [WAVE Test Runner](./README.md)

Using a configuration file, the WAVE Test Runner can be configured to be more functional in different use cases. This document lists all configuration parameters and what they are used for.

Contents

  1. Usage Guide: General usage guide
  2. Usage Guide: General usage guide

1. Results directory 2. Test Timeouts 3. Enable import of results 4. Web namespace 5. Persisting interval 6. API titles 7. Enable listing all sessions 8. Event caching duration 9. Enable test type selection

1. Location and structure

Configuration parameters are defined in a JSON file called config.json in the project root of the WPT runner. This configuration file is also used by the WPT runner, so any WAVE Test Runner related configuration parameters are wrapped inside a wave object.

<PRJ_ROOT>/config.json
{
  "wave": {
    "results": "./results"
  }
}

All the default values are stored in a configuration file inside the wave directory:

<PRJ_ROOT>/tools/wave/config.default.json
{
  "wave": {
    "results": "./results",
    "timeouts": {
      "automatic": 60000,
      "manual": 300000
    },
    "enable_import_results": false,
    "web_root": "/_wave",
    "persisting_interval": 20,
    "api_titles": [],
    "enable_read_sessions": false,
    "event_cache_duration": 60000
  }
}

🠑 top

2. Parameters

2.1 Results directory

The results parameter sets where results and session information are stored.

Parameters:

{
  "results": "<String>"
}

the project root.

Default:

{
  "results": "./results"
}

🠑 top

2.2 Test Timeouts

The test timeouts set the default test timeout for different test types.

Parameters:

{
  "timeouts": {
    "automatic": "<Number>",
    "manual": "<Number>"
  }
}

- automatic: Default time to wait for automatic tests in milliseconds. - manual: Default time to wait for manual tests in milliseconds.

Default:

{
  "timeouts": {
    "automatic": 600000,
    "manual": 300000
  }
}

🠑 top

2.3 Enable import of results

This parameter enables the capability to import session results from other WAVE Test Runner instances into the current one.

Parameters:

{
  "enable_import_results": "<Boolean>"
}

Default:

{
  "enable_import_results": "false"
}

🠑 top

2.4 Web namespace

All static resources and REST API endpoints are accessible under a configurable namespace. This namespace can be set using the web_root parameter.

Parameters:

{
  "web_root": "<String>"
}

Default:

{
  "web_root": "/_wave"
}

🠑 top

2.5 Persisting interval

The persisting interval specifies how many tests have to be completed until all session information is updated in the results directory.

For example, if set to 5, then every 5 completed tests the info.json in the results directory is updated with the current state of the session. When restarting the server, this state is used to reconstruct all sessions testing state.

Parameters:

{
  "persisting_interval": "<Number>"
}

session information gets updated

Default:

{
  "persisting_interval": 20
}

🠑 top

2.6 API titles

The API titles are used to display a more human readible representation of an API that tests are available for. Using the parameter it is possible to assign a name to an API subdirectory.

Parameters:

{
  "api_titles": [
    {
      "title": "<String>",
      "path": "<String>"
    },
    ...
  ]
}

- title: The displayed title of the API in the UI - path: The path relative to the project root of the tested API

Default:

{
  "api_titles": []
}

Example:

{
  "api_titles": [
    {
      "title": "WebGL",
      "path": "/webgl"
    },
    {
      "title": "WebRTC Extensions",
      "path": "/webrtc-extensions"
    }
  ]
}

🠑 top

2.7 Enable listing all sessions

This parameter enables the REST API endpoint to list all available sessions.

Parameters:

{
  "enable_read_sessions": "<Boolean>"
}

Default:

{
  "enable_read_sessions": "false"
}

🠑 top

2.8 Event caching duration

This parameters specifies how long events are hold in the cache. Depending on how fast clients are able to evaluate events, this value may be changed accordingly.

Parameters:

{
  "event_cache_duration": "<Number>"
}

Default:

{
  "event_cache_duration": 60000
}

🠑 top

2.9 Enable test type selection

Sets display of test type configuration UI elements.

Parameters:

{
  "enable_test_type_selection": "<Boolean>"
}

Default:

False

🠑 top