Report Portal Reporter

> wdio-reportportal-reporter is a 3rd party package, for more information please see GitHub | npm > npm > npm > A WebdriverIO v5 reporter plugin to report results to Report Portal(http:). > For v4 version see this branch > For Report Portal v4 use `` releases

Installation

The easiest way is to keep and as a devDependency in your ``.

Instructions on how to install `` can be found here.

Configuration

Configure the output directory in your wdio.conf.js file:

Complete guide with a project sample demonstrating integration of WebdriverIO with Report Portal

See readme in wdio-rp-integration-demoC

Additional API

Api methods can be accessed using:

Methods description

  • `` – send log to current suite\test item.
    • `` (string) - log level. Values ['trace', 'debug', 'info', 'warn', 'error'].
    • `` (String)– log message content.
  • `` – send file to current suite\test item.
    • `` (string) - log level. Values ['trace', 'debug', 'info', 'warn', 'error'].
    • `` (string)– file name.
    • `` (String) – attachment content
    • (_String_, optional) – attachment MIME-type, by default
  • `` - send log to specific test.
    • (_object_) - test object from wdio hook
    • `` (string) - log level. Values ['trace', 'debug', 'info', 'warn', 'error'].
    • `` (String)– log message content.
  • `` – send file to to specific test.
    • (_object_) - test object from wdio hook
    • `` (string) - log level. Values ['trace', 'debug', 'info', 'warn', 'error'].
    • `` (string)– file name.
    • `` (String) – attachment content
    • (_string_, optional) – attachment MIME-type, by default

Pay attention: \\ sends log to current running test item. It means if you send log without active test(e.g from hooks or on suite level) it will not be reported Report Portal UI.

Methods \\ are useful when you need to send screenshots or logs to the failed test item from wdio afterTest hook.

Mocha example:

WDIO Cucumber "5.14.3+" Example:

Getting link to Report Portal UI launch page

or more complicated way

Reporting test to existing launch

If you want report test to existing active launch you may pass it to reporter by environment variable `` You are responsible for finishing launch as well as starting such launch.

License

This project is licensed under the MIT License - see the LICENSE.md file for details