Running tests using Protractor framework
If your testing framework is Protractor, the SeaLights agent integrates directly with it and reports the test results to the server directly.
See https://www.npmjs.com/package/sealights-protractor-plugin for details.
Protractor is deprecated and will reach end-of-life by Summer 2023. To learn more and find out about other options please refer to this post on the Angular blog: https://goo.gle/state-of-e2e-in-angular
It is important to notice that Protractor does not run the tests on itself but relies on a framework like Jasmine
or CucumberJS
for that purpose, as defined in its configuration. In order to fully integrate with Sealights, and depending on the framework in use, you’ll need to use the relevant complimentary Sealights plugin:
CucumberJS: https://sealights.atlassian.net/l/cp/sd1i1b2Q
Installing Sealights plugin
npm install sealights-protractor-plugin
In your config file add the sealights plugin
plugins: [{
package: 'sealights-protractor-plugin',
}
Using Sealights plugin with Protactor
From the command line, add sealights parameters with --sl-
prefix
protractor protractor.conf.js --sl-tokenfile <path/to/token-file> --sl-buildsessionidfile <path/to/buildSessionId-file> --sl-labid <labid-shared-with-your-app-under-test> --sl-testStage e2e
Parameter | Description |
---|---|
| Access token generated from the SeaLights server |
| Path to file containing access token generated from the SeaLights server |
| Session ID of configuration created |
| Path to file containing the Session ID of configuration created |
| Name of the test stage |
| Unique ID for a set of test labs in case multiple labs are running simultaneously |
| Address of proxy to run connection through |
To enable logging, please refer to the slnodejs agent command reference documentation page: SeaLights Node.js agent - Command Reference | Logging