@tracera/webdriverio
v1.3.1
Published
WebdriverIO reporter, service, and runtime for Tracera autotest
Maintainers
Readme
@tracera/webdriverio
WebdriverIO reporter, service, and runtime for Tracera autotest.
Requires Node.js ≥ 22.19 and WebdriverIO ≥ 9.
npm install @tracera/webdriverioHow-to: WebdriverIO. Shared env / run mode: Autotest adapters.
Setup
// wdio.conf.ts (Mocha)
export const config = {
reporters: ['spec', ['@tracera/webdriverio/reporter', {}]],
services: [['@tracera/webdriverio/service', {}]],
mochaOpts: {
require: ['@tracera/webdriverio/setup'],
},
};For Cucumber, register the same reporter and service.
Bind
Mocha: load @tracera/webdriverio/setup, import tracera / annotations. Prefer it(title, annotations(id, name, fn)); or tracera.testCase in the body. Annotation names are literal (no {param}).
Cucumber: Scenario tags @tracera.id:‹id› (optional @tracera.name:…), or tracera.testCase from a Before hook / step.
Skip
Mocha: this.skip() (add tracera.comment first if you need a reason). Cucumber: stock pending / skipped. The reason becomes a result comment.
Steps
tracera.step(title, fn), @tracera.step("open {path}") on class methods, or tracera.step("…")(fn) wrap ({name} / {0} from args, or a title function). Stock beforeEach / afterEach → Setup / Teardown; suite hooks are not reported. Cucumber Gherkin steps map to Test; nest helpers with tracera.step / @tracera.step.
Comments, errors, and attachments
tracera.comment / tracera.error / tracera.attachment — see Autotest adapters.
Parameterized
Mocha: loop with a distinct id/name, or tracera.testCase in the body (annotation names stay literal). Cucumber Outline: native "<col>" expansion — no {param} in tags. Retries: final attempt only; WEBDRIVERIO_RETRY on Env when retry > 0.
