Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gemini-testing/testplane-headless-chrome
Plugin for Testplane to run integration tests on downloaded headless Chromium.
https://github.com/gemini-testing/testplane-headless-chrome
testplane-plugin
Last synced: 3 months ago
JSON representation
Plugin for Testplane to run integration tests on downloaded headless Chromium.
- Host: GitHub
- URL: https://github.com/gemini-testing/testplane-headless-chrome
- Owner: gemini-testing
- License: mit
- Created: 2019-08-23T15:11:33.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-04-09T15:42:15.000Z (9 months ago)
- Last Synced: 2024-10-03T05:32:08.760Z (3 months ago)
- Topics: testplane-plugin
- Language: JavaScript
- Homepage:
- Size: 188 KB
- Stars: 4
- Watchers: 10
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# @testplane/headless-chrome
Plugin for [Testplane](https://github.com/gemini-testing/testplane) to run integration tests on downloaded headless Chromium.
NB: plugin searches builds starting from last stable version, but downloaded developers version. Builds for some versions may not be found. Detail information on [article](https://www.chromium.org/getting-involved/download-chromium).
You can read more about Testplane plugins [here](https://github.com/gemini-testing/testplane#plugins).
## Installation
```bash
npm install -D @testplane/headless-chrome
```## Usage
* **enabled** (optional) `Boolean` – enable/disable the plugin; by default plugin is enabled.
* **browserId** (required) `String` - browser id on Testplane config for headless Chromium.
* **version** (optional) `Boolean` - Chromium version; latest stable version by default.
* **cachePath** (optional) `String` - path to directory for downloaded Chromium binary; */testplane-headless-chrome* on *home directory* by default.
* **downloadAttempts** (optional) `Number` - attempts count for download Chromium; `30` by default.Also there is ability to override plugin parameters by CLI options or environment variables
(see [configparser](https://github.com/gemini-testing/configparser)).
Use `testplane_headless_chrome_` prefix for the environment variables and `--headless-chrome-` for the cli options.For example you can override browserId option like so:
```bash
$ testplane_headless_chrome_browser_id=some-browser-id testplane
$ testplane --headless-chrome-browser-id some-browser-idAdd plugin to your Testplane config file:
```js
module.exports = {
// ...
browsers: {
'example-browser-id': {
desiredCapabilities: {
browserName: 'chrome',
browserVersion: '123.0'
}
}
},
// ...
plugins: {
'@testplane/headless-chrome': {
enabled: true,
browserId: 'example-browser-id',
version: '123'
}
},
//...
}
```## Testing
Run [mocha](http://mochajs.org) tests:
```bash
npm run test-unit
```Run [eslint](http://eslint.org) codestyle verification
```bash
npm run lint
```