UNPKG

@cucumber/cucumber

Version:

The official JavaScript implementation of Cucumber.

36 lines (35 loc) 1.18 kB
import { Envelope } from '@cucumber/messages'; import { RuntimeOptions } from '../index'; import { ISupportCodeCoordinates } from '../../api'; import { AssembledTestCase } from '../../assemble'; import { CanonicalSupportCodeIds } from '../../support_code_library_builder/types'; import { FormatOptions } from '../../formatter'; export type CoordinatorToWorkerCommand = InitializeCommand | RunCommand | FinalizeCommand; export interface InitializeCommand { type: 'INITIALIZE'; testRunStartedId: string; supportCodeCoordinates: ISupportCodeCoordinates; supportCodeIds: CanonicalSupportCodeIds; options: RuntimeOptions; snippetOptions: Pick<FormatOptions, 'snippetInterface' | 'snippetSyntax'>; } export interface RunCommand { type: 'RUN'; assembledTestCase: AssembledTestCase; failing: boolean; } export interface FinalizeCommand { type: 'FINALIZE'; } export type WorkerToCoordinatorEvent = ReadyEvent | EnvelopeEvent | FinishedEvent; export interface ReadyEvent { type: 'READY'; } export interface EnvelopeEvent { type: 'ENVELOPE'; envelope: Envelope; } export interface FinishedEvent { type: 'FINISHED'; success: boolean; }