@cucumber/cucumber 8.11.1 → 9.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/api/paths.js CHANGED
@@ -41,7 +41,8 @@ async function expandPaths(cwd, unexpandedPaths, defaultExtension) {
41
41
  }));
42
42
  return expanded.flat();
43
43
  }));
44
- return expandedPaths.flat().map((x) => path_1.default.normalize(x));
44
+ const normalized = expandedPaths.flat().map((x) => path_1.default.normalize(x));
45
+ return [...new Set(normalized)];
45
46
  }
46
47
  async function getUnexpandedFeaturePaths(cwd, args) {
47
48
  if (args.length > 0) {
@@ -80,7 +81,6 @@ function getFeatureDirectoryPaths(cwd, featurePaths) {
80
81
  }
81
82
  async function expandFeaturePaths(cwd, featurePaths) {
82
83
  featurePaths = featurePaths.map((p) => p.replace(/(:\d+)*$/g, '')); // Strip line numbers
83
- featurePaths = [...new Set(featurePaths)]; // Deduplicate the feature files
84
84
  return await expandPaths(cwd, featurePaths, '.feature');
85
85
  }
86
86
  async function deriveSupportPaths(cwd, featurePaths, unexpandedRequirePaths, unexpandedImportPaths) {
@@ -1 +1 @@
1
- {"version":3,"file":"paths.js","sourceRoot":"","sources":["../../src/api/paths.ts"],"names":[],"mappings":";;;;;;AAAA,+BAAgC;AAChC,gDAAuB;AACvB,gDAAuB;AACvB,+CAAsB;AAIf,KAAK,UAAU,YAAY,CAChC,MAAe,EACf,GAAW,EACX,OAA2C,EAC3C,UAAmC;IACjC,cAAc,EAAE,EAAE;IAClB,YAAY,EAAE,EAAE;IAChB,WAAW,EAAE,EAAE;CAChB;IAOD,MAAM,sBAAsB,GAAG,MAAM,yBAAyB,CAC5D,GAAG,EACH,OAAO,CAAC,KAAK,CACd,CAAA;IACD,MAAM,YAAY,GAAa,MAAM,kBAAkB,CACrD,GAAG,EACH,sBAAsB,CACvB,CAAA;IACD,MAAM,CAAC,KAAK,CAAC,6CAA6C,EAAE,YAAY,CAAC,CAAA;IACzE,MAAM,EAA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AY,GAChB,sBAAsB,CAAC,MAAM,GAAG,CAAC;QAC/B,CAAC,CAAC,MAAM,WAAW,CAAC,GAAG,EAAE,sBAAsB,EAAE,KAAK,CAAC;QACvD,CAAC,CAAC,EAAE,CAAA;IACR,MAAM,WAAW,GACf,qBAAqB,CAAC,MAAM,GAAG,CAAC;QAC9B,CAAC,CAAC,MAAM,WAAW,CAAC,GAAG,EAAE,qBAAqB,EAAE,gBAAgB,CAAC;QACjE,CAAC,CAAC,EAAE,CAAA;IACR,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,CAAA;AACtC,CAAC","sourcesContent":["import { promisify } from 'util'\nimport glob from 'glob'\nimport path from 'path'\nimport fs from 'mz/fs'\nimport { ISourcesCoordinates, ISupportCodeCoordinates } from './types'\nimport { ILogger } from '../logger'\n\nexport async function resolvePaths(\n logger: ILogger,\n cwd: string,\n sources: Pick<ISourcesCoordinates, 'paths'>,\n support: ISupportCodeCoordinates = {\n requireModules: [],\n requirePaths: [],\n importPaths: [],\n }\n): Promise<{\n unexpandedFeaturePaths: string[]\n featurePaths: string[]\n requirePaths: string[]\n importPaths: string[]\n}> {\n const unexpandedFeaturePaths = await getUnexpandedFeaturePaths(\n cwd,\n sources.paths\n )\n const featurePaths: string[] = await expandFeaturePaths(\n cwd,\n unexpandedFeaturePaths\n )\n logger.debug('Found feature files based on configuration:', featurePaths)\n const { requirePaths, importPaths } = await deriveSupportPaths(\n cwd,\n featurePaths,\n support.requirePaths,\n support.importPaths\n )\n logger.debug(\n 'Found support files to load via `require` based on configuration:',\n requirePaths\n )\n logger.debug(\n 'Found support files to load via `import` based on configuration:',\n importPaths\n )\n return {\n unexpandedFeaturePaths,\n featurePaths,\n requirePaths,\n importPaths,\n }\n}\n\nasync function expandPaths(\n cwd: string,\n unexpandedPaths: string[],\n defaultExtension: string\n): Promise<string[]> {\n const expandedPaths = await Promise.all(\n unexpandedPaths.map(async (unexpandedPath) => {\n const matches = await promisify(glob)(unexpandedPath, {\n absolute: true,\n cwd,\n })\n const expanded = await Promise.all(\n matches.map(async (match) => {\n if (path.extname(match) === '') {\n return await promisify(glob)(`${match}/**/*${defaultExtension}`)\n }\n return [match]\n })\n )\n return expanded.flat()\n })\n )\n return expandedPaths.flat().map((x) => path.normalize(x))\n}\n\nasync function getUnexpandedFeaturePaths(\n cwd: string,\n args: string[]\n): Promise<string[]> {\n if (args.length > 0) {\n const nestedFeaturePaths = await Promise.all(\n args.map(async (arg) => {\n const filename = path.basename(arg)\n if (filename[0] === '@') {\n const filePath = path.join(cwd, arg)\n const content = await fs.readFile(filePath, 'utf8')\n return content.split('\\n').map((x) => x.trim())\n }\n return [arg]\n })\n )\n const featurePaths = nestedFeaturePaths.flat()\n if (featurePaths.length > 0) {\n return featurePaths.filter((x) => x !== '')\n }\n }\n return ['features/**/*.{feature,feature.md}']\n}\n\nfunction getFeatureDirectoryPaths(\n cwd: string,\n featurePaths: string[]\n): string[] {\n const featureDirs = featurePaths.map((featurePath) => {\n let featureDir = path.dirname(featurePath)\n let childDir: string\n let parentDir = featureDir\n while (childDir !== parentDir) {\n childDir = parentDir\n parentDir = path.dirname(childDir)\n if (path.basename(parentDir) === 'features') {\n featureDir = parentDir\n break\n }\n }\n return path.relative(cwd, featureDir)\n })\n return [...new Set(featureDirs)]\n}\n\nasync function expandFeaturePaths(\n cwd: string,\n featurePaths: string[]\n): Promise<string[]> {\n featurePaths = featurePaths.map((p) => p.replace(/(:\\d+)*$/g, '')) // Strip line numbers\n featurePaths = [...new Set(featurePaths)] // Deduplicate the feature files\n return await expandPaths(cwd, featurePaths, '.feature')\n}\n\nasync function deriveSupportPaths(\n cwd: string,\n featurePaths: string[],\n unexpandedRequirePaths: string[],\n unexpandedImportPaths: string[]\n): Promise<{\n requirePaths: string[]\n importPaths: string[]\n}> {\n if (\n unexpandedRequirePaths.length === 0 &&\n unexpandedImportPaths.length === 0\n ) {\n const defaultPaths = getFeatureDirectoryPaths(cwd, featurePaths)\n const requirePaths = await expandPaths(cwd, defaultPaths, '.js')\n const importPaths = await expandPaths(cwd, defaultPaths, '.mjs')\n return { requirePaths, importPaths }\n }\n const requirePaths =\n unexpandedRequirePaths.length > 0\n ? await expandPaths(cwd, unexpandedRequirePaths, '.js')\n : []\n const importPaths =\n unexpandedImportPaths.length > 0\n ? await expandPaths(cwd, unexpandedImportPaths, '.@(js|cjs|mjs)')\n : []\n return { requirePaths, importPaths }\n}\n"]}
1
+ {"version":3,"file":"paths.js","sourceRoot":"","sources":["../../src/api/paths.ts"],"names":[],"mappings":";;;;;;AAAA,+BAAgC;AAChC,gDAAuB;AACvB,gDAAuB;AACvB,+CAAsB;AAIf,KAAK,UAAU,YAAY,CAChC,MAAe,EACf,GAAW,EACX,OAA2C,EAC3C,UAAmC;IACjC,cAAc,EAAE,EAAE;IAClB,YAAY,EAAE,EAAE;IAChB,WAAW,EAAE,EAAE;CAChB;IAOD,MAAM,sBAAsB,GAAG,MAAM,yBAAyB,CAC5D,GAAG,EACH,OAAO,CAAC,KAAK,CACd,CAAA;IACD,MAAM,YAAY,GAAa,MAAM,kBAAkB,CACrD,GAAG,EACH,sBAAsB,CACvB,CAAA;IACD,MAAM,CAAC,KAAK,CAAC,6CAA6C,EAAE,YAAY,CAAC,CAAA;IACzE,MAAM,EAAE,YAAY,EAAE,WAAW,EAAE,GAAG,MAAM,kBAAkB,CAC5D,GAAG,EACH,YAAY,EACZ,OAAO,CAAC,YAAY,EACpB,OAAO,CAAC,WAAW,CACpB,CAAA;IACD,MAAM,CAAC,KAAK,CACV,mEAAmE,EACnE,YAAY,CACb,CAAA;IACD,MAAM,CAAC,KAAK,CACV,kEAAkE,EAClE,WAAW,CACZ,CAAA;IACD,OAAO;QACL,sBAAsB;QACtB,YAAY;QACZ,YAAY;QACZ,WAAW;KACZ,CAAA;AACH,CAAC;AA5CD,oCA4CC;AAED,KAAK,UAAU,WAAW,CACxB,GAAW,EACX,eAAyB,EACzB,gBAAwB;IAExB,MAAM,aAAa,GAAG,MAAM,OAAO,CAAC,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A;AAClC,CAAC;AAED,KAAK,UAAU,kBAAkB,CAC/B,GAAW,EACX,YAAsB;IAEtB,YAAY,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,CAAA,CAAC,qBAAqB;IACxF,OAAO,MAAM,WAAW,CAAC,GAAG,EAAE,YAAY,EAAE,UAAU,CAAC,CAAA;AACzD,CAAC;AAED,KAAK,UAAU,kBAAkB,CAC/B,GAAW,EACX,YAAsB,EACtB,sBAAgC,EAChC,qBAA+B;IAK/B,IACE,sBAAsB,CAAC,MAAM,KAAK,CAAC;QACnC,qBAAqB,CAAC,MAAM,KAAK,CAAC,EAClC;QACA,MAAM,YAAY,GAAG,wBAAwB,CAAC,GAAG,EAAE,YAAY,CAAC,CAAA;QAChE,MAAM,YAAY,GAAG,MAAM,WAAW,CAAC,GAAG,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;QAChE,MAAM,WAAW,GAAG,MAAM,WAAW,CAAC,GAAG,EAAE,YAAY,EAAE,MAAM,CAAC,CAAA;QAChE,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,CAAA;KACrC;IACD,MAAM,YAAY,GAChB,sBAAsB,CAAC,MAAM,GAAG,CAAC;QAC/B,CAAC,CAAC,MAAM,WAAW,CAAC,GAAG,EAAE,sBAAsB,EAAE,KAAK,CAAC;QACvD,CAAC,CAAC,EAAE,CAAA;IACR,MAAM,WAAW,GACf,qBAAqB,CAAC,MAAM,GAAG,CAAC;QAC9B,CAAC,CAAC,MAAM,WAAW,CAAC,GAAG,EAAE,qBAAqB,EAAE,gBAAgB,CAAC;QACjE,CAAC,CAAC,EAAE,CAAA;IACR,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,CAAA;AACtC,CAAC","sourcesContent":["import { promisify } from 'util'\nimport glob from 'glob'\nimport path from 'path'\nimport fs from 'mz/fs'\nimport { ISourcesCoordinates, ISupportCodeCoordinates } from './types'\nimport { ILogger } from '../logger'\n\nexport async function resolvePaths(\n logger: ILogger,\n cwd: string,\n sources: Pick<ISourcesCoordinates, 'paths'>,\n support: ISupportCodeCoordinates = {\n requireModules: [],\n requirePaths: [],\n importPaths: [],\n }\n): Promise<{\n unexpandedFeaturePaths: string[]\n featurePaths: string[]\n requirePaths: string[]\n importPaths: string[]\n}> {\n const unexpandedFeaturePaths = await getUnexpandedFeaturePaths(\n cwd,\n sources.paths\n )\n const featurePaths: string[] = await expandFeaturePaths(\n cwd,\n unexpandedFeaturePaths\n )\n logger.debug('Found feature files based on configuration:', featurePaths)\n const { requirePaths, importPaths } = await deriveSupportPaths(\n cwd,\n featurePaths,\n support.requirePaths,\n support.importPaths\n )\n logger.debug(\n 'Found support files to load via `require` based on configuration:',\n requirePaths\n )\n logger.debug(\n 'Found support files to load via `import` based on configuration:',\n importPaths\n )\n return {\n unexpandedFeaturePaths,\n featurePaths,\n requirePaths,\n importPaths,\n }\n}\n\nasync function expandPaths(\n cwd: string,\n unexpandedPaths: string[],\n defaultExtension: string\n): Promise<string[]> {\n const expandedPaths = await Promise.all(\n unexpandedPaths.map(async (unexpandedPath) => {\n const matches = await promisify(glob)(unexpandedPath, {\n absolute: true,\n cwd,\n })\n const expanded = await Promise.all(\n matches.map(async (match) => {\n if (path.extname(match) === '') {\n return await promisify(glob)(`${match}/**/*${defaultExtension}`)\n }\n return [match]\n })\n )\n return expanded.flat()\n })\n )\n const normalized = expandedPaths.flat().map((x) => path.normalize(x))\n return [...new Set(normalized)]\n}\n\nasync function getUnexpandedFeaturePaths(\n cwd: string,\n args: string[]\n): Promise<string[]> {\n if (args.length > 0) {\n const nestedFeaturePaths = await Promise.all(\n args.map(async (arg) => {\n const filename = path.basename(arg)\n if (filename[0] === '@') {\n const filePath = path.join(cwd, arg)\n const content = await fs.readFile(filePath, 'utf8')\n return content.split('\\n').map((x) => x.trim())\n }\n return [arg]\n })\n )\n const featurePaths = nestedFeaturePaths.flat()\n if (featurePaths.length > 0) {\n return featurePaths.filter((x) => x !== '')\n }\n }\n return ['features/**/*.{feature,feature.md}']\n}\n\nfunction getFeatureDirectoryPaths(\n cwd: string,\n featurePaths: string[]\n): string[] {\n const featureDirs = featurePaths.map((featurePath) => {\n let featureDir = path.dirname(featurePath)\n let childDir: string\n let parentDir = featureDir\n while (childDir !== parentDir) {\n childDir = parentDir\n parentDir = path.dirname(childDir)\n if (path.basename(parentDir) === 'features') {\n featureDir = parentDir\n break\n }\n }\n return path.relative(cwd, featureDir)\n })\n return [...new Set(featureDirs)]\n}\n\nasync function expandFeaturePaths(\n cwd: string,\n featurePaths: string[]\n): Promise<string[]> {\n featurePaths = featurePaths.map((p) => p.replace(/(:\\d+)*$/g, '')) // Strip line numbers\n return await expandPaths(cwd, featurePaths, '.feature')\n}\n\nasync function deriveSupportPaths(\n cwd: string,\n featurePaths: string[],\n unexpandedRequirePaths: string[],\n unexpandedImportPaths: string[]\n): Promise<{\n requirePaths: string[]\n importPaths: string[]\n}> {\n if (\n unexpandedRequirePaths.length === 0 &&\n unexpandedImportPaths.length === 0\n ) {\n const defaultPaths = getFeatureDirectoryPaths(cwd, featurePaths)\n const requirePaths = await expandPaths(cwd, defaultPaths, '.js')\n const importPaths = await expandPaths(cwd, defaultPaths, '.mjs')\n return { requirePaths, importPaths }\n }\n const requirePaths =\n unexpandedRequirePaths.length > 0\n ? await expandPaths(cwd, unexpandedRequirePaths, '.js')\n : []\n const importPaths =\n unexpandedImportPaths.length > 0\n ? await expandPaths(cwd, unexpandedImportPaths, '.@(js|cjs|mjs)')\n : []\n return { requirePaths, importPaths }\n}\n"]}
@@ -11,9 +11,6 @@ class JavaScriptSnippetSyntax {
11
11
  if (this.snippetInterface === snippet_syntax_1.SnippetInterface.AsyncAwait) {
12
12
  functionKeyword = 'async ' + functionKeyword;
13
13
  }
14
- else if (this.snippetInterface === snippet_syntax_1.SnippetInterface.Generator) {
15
- functionKeyword += '*';
16
- }
17
14
  let implementation;
18
15
  if (this.snippetInterface === snippet_syntax_1.SnippetInterface.Callback) {
19
16
  implementation = `${CALLBACK_NAME}(null, 'pending');`;
@@ -1 +1 @@
1
- {"version":3,"file":"javascript_snippet_syntax.js","sourceRoot":"","sources":["../../../src/formatter/step_definition_snippet_builder/javascript_snippet_syntax.ts"],"names":[],"mappings":";;AACA,qDAIyB;AAEzB,MAAM,aAAa,GAAG,UAAU,CAAA;AAEhC,MAAqB,uBAAuB;IAG1C,YAAY,gBAAkC;QAC5C,IAAI,CAAC,gBAAgB,GAAG,gBAAgB,CAAA;IAC1C,CAAC;IAED,KAAK,CAAC,EACJ,OAAO,EACP,oBAAoB,EACpB,YAAY,EACZ,kBAAkB,GACS;QAC3B,IAAI,eAAe,GAAG,WAAW,CAAA;QACjC,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,UAAU,EAAE;YACzD,eAAe,GAAG,QAAQ,GAAG,eAAe,CAAA;SAC7C;aAAM,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,SAAS,EAAE;YAC/D,eAAe,IAAI,GAAG,CAAA;SACvB;QAED,IAAI,cAAsB,CAAA;QAC1B,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,QAAQ,EAAE;YACvD,cAAc,GAAG,GAAG,aAAa,oBAAoB,CAAA;SACtD;aAAM,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,OAAO,EAAE;YAC7D,cAAc,GAAG,oCAAoC,CAAA;SACtD;aAAM;YACL,cAAc,GAAG,mBAAmB,CAAA;SACrC;QAED,MAAM,iBAAiB,GAAG,oBAAoB,CAAC,GAAG,CAChD,CAAC,mBAAmB,EAAE,KAAK,EAAE,EAAE;YAC7B,MAAM,MAAM,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAA;YACvC,MAAM,iBAAiB,GACrB,mBAAmB,CAAC,cAAc,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAA;YAC/D,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,QAAQ,EAAE;gBACvD,iBAAiB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAA;aACtC;YACD,OAAO,GAAG,MAAM,GAAG,YAAY,KAAK,IAAI,CAAC,uBAAuB,CAC9D,mBAAmB,CACpB,MAAM,eAAe,IAAI,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAA;QAC/D,CAAC,CACF,CAAA;QAED,OAAO,CACL,GAAG,iBAAiB,CAAC,IAAI,CAAC,EAAE,CAAC,QAAQ,OAAO,IAAI;YAChD,KAAK,cAAc,IAAI;YACvB,KAAK,CACN,CAAA;IACH,CAAC;IAEO,uBAAuB,CAAC,mBAAwC;QACtE,IAAI,MAAM,GAAG,mBAAmB,CAAC,MAAM,CAAA;QACvC,iEAAiE;QACjE,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,CAAA;QACtC,8DAA8D;QAC9D,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;QACpC,OAAO,MAAM,CAAA;IACf,CAAC;CACF;AA1DD,0CA0DC","sourcesContent":["import { GeneratedExpression } from '@cucumber/cucumber-expressions'\nimport {\n ISnippetSnytax,\n ISnippetSyntaxBuildOptions,\n SnippetInterface,\n} from './snippet_syntax'\n\nconst CALLBACK_NAME = 'callback'\n\nexport default class JavaScriptSnippetSyntax implements ISnippetSnytax {\n private readonly snippetInterface: SnippetInterface\n\n constructor(snippetInterface: SnippetInterface) {\n this.snippetInterface = snippetInterface\n }\n\n build({\n comment,\n generatedExpressions,\n functionName,\n stepParameterNames,\n }: ISnippetSyntaxBuildOptions): string {\n let functionKeyword = 'function '\n if (this.snippetInterface === SnippetInterface.AsyncAwait) {\n functionKeyword = 'async ' + functionKeyword\n } else if (this.snippetInterface === SnippetInterface.Generator) {\n functionKeyword += '*'\n }\n\n let implementation: string\n if (this.snippetInterface === SnippetInterface.Callback) {\n implementation = `${CALLBACK_NAME}(null, 'pending');`\n } else if (this.snippetInterface === SnippetInterface.Promise) {\n implementation = \"return Promise.resolve('pending');\"\n } else {\n implementation = \"return 'pending';\"\n }\n\n const definitionChoices = generatedExpressions.map(\n (generatedExpression, index) => {\n const prefix = index === 0 ? '' : '// '\n const allParameterNames =\n generatedExpression.parameterNames.concat(stepParameterNames)\n if (this.snippetInterface === SnippetInterface.Callback) {\n allParameterNames.push(CALLBACK_NAME)\n }\n return `${prefix + functionName}('${this.escapeSpecialCharacters(\n generatedExpression\n )}', ${functionKeyword}(${allParameterNames.join(', ')}) {\\n`\n }\n )\n\n return (\n `${definitionChoices.join('')} // ${comment}\\n` +\n ` ${implementation}\\n` +\n '});'\n )\n }\n\n private escapeSpecialCharacters(generatedExpression: GeneratedExpression) {\n let source = generatedExpression.source\n // double up any backslashes because we're in a javascript string\n source = source.replace(/\\\\/g, '\\\\\\\\')\n // escape any single quotes because that's our quote delimiter\n source = source.replace(/'/g, \"\\\\'\")\n return source\n }\n}\n"]}
1
+ {"version":3,"file":"javascript_snippet_syntax.js","sourceRoot":"","sources":["../../../src/formatter/step_definition_snippet_builder/javascript_snippet_syntax.ts"],"names":[],"mappings":";;AACA,qDAIyB;AAEzB,MAAM,aAAa,GAAG,UAAU,CAAA;AAEhC,MAAqB,uBAAuB;IAG1C,YAAY,gBAAkC;QAC5C,IAAI,CAAC,gBAAgB,GAAG,gBAAgB,CAAA;IAC1C,CAAC;IAED,KAAK,CAAC,EACJ,OAAO,EACP,oBAAoB,EACpB,YAAY,EACZ,kBAAkB,GACS;QAC3B,IAAI,eAAe,GAAG,WAAW,CAAA;QACjC,IAAI,IAAI,CAAC,gBAAgB,KAAK,iCAAgB,CAAC,UAAU,EAAE;YACzD,eAAe,GAAG,QAAQ,GAAG,eAAe,CAAA;SAC7C;QAED,IAAI,cAAsB,CAAA;QAC1B,IAAI,IAAI,CAAC,gBAAgB,KAAK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AAxDD,0CAwDC","sourcesContent":["import { GeneratedExpression } from '@cucumber/cucumber-expressions'\nimport {\n ISnippetSnytax,\n ISnippetSyntaxBuildOptions,\n SnippetInterface,\n} from './snippet_syntax'\n\nconst CALLBACK_NAME = 'callback'\n\nexport default class JavaScriptSnippetSyntax implements ISnippetSnytax {\n private readonly snippetInterface: SnippetInterface\n\n constructor(snippetInterface: SnippetInterface) {\n this.snippetInterface = snippetInterface\n }\n\n build({\n comment,\n generatedExpressions,\n functionName,\n stepParameterNames,\n }: ISnippetSyntaxBuildOptions): string {\n let functionKeyword = 'function '\n if (this.snippetInterface === SnippetInterface.AsyncAwait) {\n functionKeyword = 'async ' + functionKeyword\n }\n\n let implementation: string\n if (this.snippetInterface === SnippetInterface.Callback) {\n implementation = `${CALLBACK_NAME}(null, 'pending');`\n } else if (this.snippetInterface === SnippetInterface.Promise) {\n implementation = \"return Promise.resolve('pending');\"\n } else {\n implementation = \"return 'pending';\"\n }\n\n const definitionChoices = generatedExpressions.map(\n (generatedExpression, index) => {\n const prefix = index === 0 ? '' : '// '\n const allParameterNames =\n generatedExpression.parameterNames.concat(stepParameterNames)\n if (this.snippetInterface === SnippetInterface.Callback) {\n allParameterNames.push(CALLBACK_NAME)\n }\n return `${prefix + functionName}('${this.escapeSpecialCharacters(\n generatedExpression\n )}', ${functionKeyword}(${allParameterNames.join(', ')}) {\\n`\n }\n )\n\n return (\n `${definitionChoices.join('')} // ${comment}\\n` +\n ` ${implementation}\\n` +\n '});'\n )\n }\n\n private escapeSpecialCharacters(generatedExpression: GeneratedExpression) {\n let source = generatedExpression.source\n // double up any backslashes because we're in a javascript string\n source = source.replace(/\\\\/g, '\\\\\\\\')\n // escape any single quotes because that's our quote delimiter\n source = source.replace(/'/g, \"\\\\'\")\n return source\n }\n}\n"]}
@@ -2,7 +2,6 @@ import { GeneratedExpression } from '@cucumber/cucumber-expressions';
2
2
  export declare enum SnippetInterface {
3
3
  AsyncAwait = "async-await",
4
4
  Callback = "callback",
5
- Generator = "generator",
6
5
  Promise = "promise",
7
6
  Synchronous = "synchronous"
8
7
  }
@@ -5,7 +5,6 @@ var SnippetInterface;
5
5
  (function (SnippetInterface) {
6
6
  SnippetInterface["AsyncAwait"] = "async-await";
7
7
  SnippetInterface["Callback"] = "callback";
8
- SnippetInterface["Generator"] = "generator";
9
8
  SnippetInterface["Promise"] = "promise";
10
9
  SnippetInterface["Synchronous"] = "synchronous";
11
10
  })(SnippetInterface = exports.SnippetInterface || (exports.SnippetInterface = {}));
@@ -1 +1 @@
1
- {"version":3,"file":"snippet_syntax.js","sourceRoot":"","sources":["../../../src/formatter/step_definition_snippet_builder/snippet_syntax.ts"],"names":[],"mappings":";;;AAEA,IAAY,gBAMX;AAND,WAAY,gBAAgB;IAC1B,8CAA0B,CAAA;IAC1B,yCAAqB,CAAA;IACrB,2CAAuB,CAAA;IACvB,uCAAmB,CAAA;IACnB,+CAA2B,CAAA;AAC7B,CAAC,EANW,gBAAgB,GAAhB,wBAAgB,KAAhB,wBAAgB,QAM3B","sourcesContent":["import { GeneratedExpression } from '@cucumber/cucumber-expressions'\n\nexport enum SnippetInterface {\n AsyncAwait = 'async-await',\n Callback = 'callback',\n Generator = 'generator',\n Promise = 'promise',\n Synchronous = 'synchronous',\n}\n\nexport interface ISnippetSyntaxBuildOptions {\n comment: string\n functionName: string\n generatedExpressions: readonly GeneratedExpression[]\n stepParameterNames: string[]\n}\n\nexport interface ISnippetSnytax {\n build: (options: ISnippetSyntaxBuildOptions) => string\n}\n"]}
1
+ {"version":3,"file":"snippet_syntax.js","sourceRoot":"","sources":["../../../src/formatter/step_definition_snippet_builder/snippet_syntax.ts"],"names":[],"mappings":";;;AAEA,IAAY,gBAKX;AALD,WAAY,gBAAgB;IAC1B,8CAA0B,CAAA;IAC1B,yCAAqB,CAAA;IACrB,uCAAmB,CAAA;IACnB,+CAA2B,CAAA;AAC7B,CAAC,EALW,gBAAgB,GAAhB,wBAAgB,KAAhB,wBAAgB,QAK3B","sourcesContent":["import { GeneratedExpression } from '@cucumber/cucumber-expressions'\n\nexport enum SnippetInterface {\n AsyncAwait = 'async-await',\n Callback = 'callback',\n Promise = 'promise',\n Synchronous = 'synchronous',\n}\n\nexport interface ISnippetSyntaxBuildOptions {\n comment: string\n functionName: string\n generatedExpressions: readonly GeneratedExpression[]\n stepParameterNames: string[]\n}\n\nexport interface ISnippetSnytax {\n build: (options: ISnippetSyntaxBuildOptions) => string\n}\n"]}
package/lib/index.d.ts CHANGED
@@ -25,6 +25,7 @@ export declare const AfterStep: (<WorldType = import("./support_code_library_bui
25
25
  export declare const Before: (<WorldType = import("./support_code_library_builder/world").IWorld<any>>(code: import("./support_code_library_builder/types").TestCaseHookFunction<WorldType>) => void) & (<WorldType_1 = import("./support_code_library_builder/world").IWorld<any>>(tags: string, code: import("./support_code_library_builder/types").TestCaseHookFunction<WorldType_1>) => void) & (<WorldType_2 = import("./support_code_library_builder/world").IWorld<any>>(options: import("./support_code_library_builder/types").IDefineTestCaseHookOptions, code: import("./support_code_library_builder/types").TestCaseHookFunction<WorldType_2>) => void);
26
26
  export declare const BeforeAll: ((code: Function) => void) & ((options: import("./support_code_library_builder/types").IDefineTestRunHookOptions, code: Function) => void);
27
27
  export declare const BeforeStep: (<WorldType = import("./support_code_library_builder/world").IWorld<any>>(code: import("./support_code_library_builder/types").TestStepHookFunction<WorldType>) => void) & (<WorldType_1 = import("./support_code_library_builder/world").IWorld<any>>(tags: string, code: import("./support_code_library_builder/types").TestStepHookFunction<WorldType_1>) => void) & (<WorldType_2 = import("./support_code_library_builder/world").IWorld<any>>(options: import("./support_code_library_builder/types").IDefineTestStepHookOptions, code: import("./support_code_library_builder/types").TestStepHookFunction<WorldType_2>) => void);
28
+ export declare const defineStep: import("./support_code_library_builder/types").IDefineStep;
28
29
  export declare const defineParameterType: (options: import("./support_code_library_builder/types").IParameterTypeDefinition<any>) => void;
29
30
  export declare const Given: import("./support_code_library_builder/types").IDefineStep;
30
31
  export declare const setDefaultTimeout: (milliseconds: number) => void;
@@ -42,10 +43,6 @@ export { wrapPromiseWithTimeout } from './time';
42
43
  * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
43
44
  */
44
45
  export declare const Cli: typeof _Cli;
45
- /**
46
- * @deprecated use `Given`, `When` or `Then` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
47
- */
48
- export declare const defineStep: import("./support_code_library_builder/types").IDefineStep;
49
46
  /**
50
47
  * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
51
48
  */
@@ -55,7 +52,7 @@ export declare const parseGherkinMessageStream: typeof cliHelpers.parseGherkinMe
55
52
  */
56
53
  export declare const PickleFilter: typeof _PickleFilter;
57
54
  /**
58
- * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
55
+ * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
59
56
  */
60
57
  export declare const Runtime: typeof _Runtime;
61
58
  export { INewRuntimeOptions, IRuntimeOptions } from './runtime';
package/lib/index.js CHANGED
@@ -26,7 +26,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
26
26
  return (mod && mod.__esModule) ? mod : { "default": mod };
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.Runtime = exports.PickleFilter = exports.parseGherkinMessageStream = exports.defineStep = exports.Cli = exports.wrapPromiseWithTimeout = exports.Status = exports.parallelCanAssignHelpers = exports.World = exports.When = exports.Then = exports.setParallelCanAssign = exports.setWorldConstructor = exports.setDefinitionFunctionWrapper = exports.setDefaultTimeout = exports.Given = exports.defineParameterType = exports.BeforeStep = exports.BeforeAll = exports.Before = exports.AfterStep = exports.AfterAll = exports.After = exports.formatterHelpers = exports.UsageJsonFormatter = exports.UsageFormatter = exports.SummaryFormatter = exports.SnippetsFormatter = exports.RerunFormatter = exports.ProgressFormatter = exports.JsonFormatter = exports.FormatterBuilder = exports.Formatter = exports.version = exports.TestCaseHookDefinition = exports.DataTable = exports.supportCodeLibraryBuilder = void 0;
29
+ exports.Runtime = exports.PickleFilter = exports.parseGherkinMessageStream = exports.Cli = exports.wrapPromiseWithTimeout = exports.Status = exports.parallelCanAssignHelpers = exports.World = exports.When = exports.Then = exports.setParallelCanAssign = exports.setWorldConstructor = exports.setDefinitionFunctionWrapper = exports.setDefaultTimeout = exports.Given = exports.defineParameterType = exports.defineStep = exports.BeforeStep = exports.BeforeAll = exports.Before = exports.AfterStep = exports.AfterAll = exports.After = exports.formatterHelpers = exports.UsageJsonFormatter = exports.UsageFormatter = exports.SummaryFormatter = exports.SnippetsFormatter = exports.RerunFormatter = exports.ProgressFormatter = exports.JsonFormatter = exports.FormatterBuilder = exports.Formatter = exports.version = exports.TestCaseHookDefinition = exports.DataTable = exports.supportCodeLibraryBuilder = void 0;
30
30
  const cli_1 = __importDefault(require("./cli"));
31
31
  const cliHelpers = __importStar(require("./cli/helpers"));
32
32
  const formatterHelpers = __importStar(require("./formatter/helpers"));
@@ -74,6 +74,7 @@ exports.AfterStep = methods.AfterStep;
74
74
  exports.Before = methods.Before;
75
75
  exports.BeforeAll = methods.BeforeAll;
76
76
  exports.BeforeStep = methods.BeforeStep;
77
+ exports.defineStep = methods.defineStep;
77
78
  exports.defineParameterType = methods.defineParameterType;
78
79
  exports.Given = methods.Given;
79
80
  exports.setDefaultTimeout = methods.setDefaultTimeout;
@@ -93,10 +94,6 @@ Object.defineProperty(exports, "wrapPromiseWithTimeout", { enumerable: true, get
93
94
  * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
94
95
  */
95
96
  exports.Cli = (0, util_1.deprecate)(cli_1.default, '`Cli` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md');
96
- /**
97
- * @deprecated use `Given`, `When` or `Then` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
98
- */
99
- exports.defineStep = (0, util_1.deprecate)(methods.defineStep, '`defineStep` is deprecated, use `Given`, `When` or `Then` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md');
100
97
  /**
101
98
  * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
102
99
  */
@@ -106,7 +103,7 @@ exports.parseGherkinMessageStream = (0, util_1.deprecate)(cliHelpers.parseGherki
106
103
  */
107
104
  exports.PickleFilter = (0, util_1.deprecate)(pickle_filter_1.default, '`PickleFilter` is deprecated, use `loadSources` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md');
108
105
  /**
109
- * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
106
+ * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
110
107
  */
111
108
  exports.Runtime = (0, util_1.deprecate)(runtime_1.default, '`Runtime` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md');
112
109
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAuC;AACvC,0DAA2C;AAC3C,sEAAuD;AAwB9C,4CAAgB;AAvBzB,oEAA0D;AAC1D,qHAAsG;AA6C7F,4DAAwB;AA5CjC,wDAA+C;AAC/C,kGAAsE;AACtE,6DAA8C;AAC9C,+BAAgC;AAEhC,YAAY;AACZ,+EAAqF;AAA5E,0JAAA,OAAO,OAA6B;AAC7C,kDAA0D;AAAjD,wHAAA,OAAO,OAAa;AAC7B,gFAAsF;AAA7E,oJAAA,OAAO,OAA0B;AAC1C,qCAAmC;AAA1B,kGAAA,OAAO,OAAA;AAEhB,aAAa;AACb,yCAAqE;AAA5D,uHAAA,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BAA+C;AAAtC,8GAAA,sBAAsB,OAAA;AAE/B,aAAa;AACb;;GAEG;AACU,QAAA,GAAG,GAAG,IAAA,gBAAS,EAC1B,aAAI,EACJ,4HAA4H,CAC7H,CAAA;AACD;;GAEG;AACU,QAAA,UAAU,GAAG,IAAA,gBAAS,EACjC,OAAO,CAAC,UAAU,EAClB,+IAA+I,CAChJ,CAAA;AACD;;GAEG;AACU,QAAA,yBAAyB,GAAG,IAAA,gBAAS,EAChD,UAAU,CAAC,yBAAyB,EACpC,kJAAkJ,CACnJ,CAAA;AACD;;GAEG;AACU,QAAA,YAAY,GAAG,IAAA,gBAAS,EACnC,uBAAa,EACb,qIAAqI,CACtI,CAAA;AACD;;GAEG;AACU,QAAA,OAAO,GAAG,IAAA,gBAAS,EAC9B,iBAAQ,EACR,gIAAgI,CACjI,CAAA","sourcesContent":["import { default as _Cli } from './cli'\nimport * as cliHelpers from './cli/helpers'\nimport * as formatterHelpers from './formatter/helpers'\nimport { default as _PickleFilter } from './pickle_filter'\nimport * as parallelCanAssignHelpers from './support_code_library_builder/parallel_can_assign_helpers'\nimport { default as _Runtime } from './runtime'\nimport supportCodeLibraryBuilder from './support_code_library_builder'\nimport * as messages from '@cucumber/messages'\nimport { deprecate } from 'util'\n\n// Top level\nexport { default as supportCodeLibraryBuilder } from './support_code_library_builder'\nexport { default as DataTable } from './models/data_table'\nexport { default as TestCaseHookDefinition } from './models/test_case_hook_definition'\nexport { version } from './version'\n\n// Formatters\nexport { default as Formatter, IFormatterOptions } from './formatter'\nexport { default as FormatterBuilder } from './formatter/builder'\nexport { default as JsonFormatter } from './formatter/json_formatter'\nexport { default as ProgressFormatter } from './formatter/progress_formatter'\nexport { default as RerunFormatter } from './formatter/rerun_formatter'\nexport { default as SnippetsFormatter } from './formatter/snippets_formatter'\nexport { default as SummaryFormatter } from './formatter/summary_formatter'\nexport { default as UsageFormatter } from './formatter/usage_formatter'\nexport { default as UsageJsonFormatter } from './formatter/usage_json_formatter'\nexport { formatterHelpers }\n\n// Support Code Functions\nconst { methods } = supportCodeLibraryBuilder\nexport const After = methods.After\nexport const AfterAll = methods.AfterAll\nexport const AfterStep = methods.AfterStep\nexport const Before = methods.Before\nexport const BeforeAll = methods.BeforeAll\nexport const BeforeStep = methods.BeforeStep\nexport const defineParameterType = methods.defineParameterType\nexport const Given = methods.Given\nexport const setDefaultTimeout = methods.setDefaultTimeout\nexport const setDefinitionFunctionWrapper = methods.setDefinitionFunctionWrapper\nexport const setWorldConstructor = methods.setWorldConstructor\nexport const setParallelCanAssign = methods.setParallelCanAssign\nexport const Then = methods.Then\nexport const When = methods.When\nexport {\n default as World,\n IWorld,\n IWorldOptions,\n} from './support_code_library_builder/world'\nexport { parallelCanAssignHelpers }\n\nexport {\n ITestCaseHookParameter,\n ITestStepHookParameter,\n} from './support_code_library_builder/types'\nexport const Status = messages.TestStepResultStatus\n\n// Time helpers\nexport { wrapPromiseWithTimeout } from './time'\n\n// Deprecated\n/**\n * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const Cli = deprecate(\n _Cli,\n '`Cli` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `Given`, `When` or `Then` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const defineStep = deprecate(\n methods.defineStep,\n '`defineStep` is deprecated, use `Given`, `When` or `Then` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const parseGherkinMessageStream = deprecate(\n cliHelpers.parseGherkinMessageStream,\n '`parseGherkinMessageStream` is deprecated, use `loadSources` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const PickleFilter = deprecate(\n _PickleFilter,\n '`PickleFilter` is deprecated, use `loadSources` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const Runtime = deprecate(\n _Runtime,\n '`Runtime` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\nexport { INewRuntimeOptions, IRuntimeOptions } from './runtime'\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAuC;AACvC,0DAA2C;AAC3C,sEAAuD;AAwB9C,4CAAgB;AAvBzB,oEAA0D;AAC1D,qHAAsG;AA8C7F,4DAAwB;AA7CjC,wDAA+C;AAC/C,kGAAsE;AACtE,6DAA8C;AAC9C,+BAAgC;AAEhC,YAAY;AACZ,+EAAqF;AAA5E,0JAAA,OAAO,OAA6B;AAC7C,kDAA0D;AAAjD,wHAAA,OAAO,OAAa;AAC7B,gFAAsF;AAA7E,oJAAA,OAAO,OAA0B;AAC1C,qCAAmC;AAA1B,kGAAA,OAAO,OAAA;AAEhB,aAAa;AACb,yCAAqE;AAA5D,uHAAA,OAAO,OAAa;AAC7B,+CAAiE;AAAxD,4HAAA,OAAO,OAAoB;AACpC,6DAAqE;AAA5D,gIAAA,OAAO,OAAiB;AACjC,qEAA6E;AAApE,wIAAA,OAAO,OAAqB;AACrC,+DAAuE;AAA9D,kIAAA,OAAO,OAAkB;AAClC,qEAA6E;AAApE,wIAAA,OAAO,OAAqB;AACrC,mEAA2E;AAAlE,sIAAA,OAAO,OAAoB;AACpC,+DAAuE;AAA9D,kIAAA,OAAO,OAAkB;AAClC,yEAAgF;AAAvE,2IAAA,OAAO,OAAsB;AAGtC,yBAAyB;AACzB,MAAM,EAAE,OAAO,EAAE,GAAG,sCA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OAAO,GAAG,IAAA,gBAAS,EAC9B,iBAAQ,EACR,gIAAgI,CACjI,CAAA","sourcesContent":["import { default as _Cli } from './cli'\nimport * as cliHelpers from './cli/helpers'\nimport * as formatterHelpers from './formatter/helpers'\nimport { default as _PickleFilter } from './pickle_filter'\nimport * as parallelCanAssignHelpers from './support_code_library_builder/parallel_can_assign_helpers'\nimport { default as _Runtime } from './runtime'\nimport supportCodeLibraryBuilder from './support_code_library_builder'\nimport * as messages from '@cucumber/messages'\nimport { deprecate } from 'util'\n\n// Top level\nexport { default as supportCodeLibraryBuilder } from './support_code_library_builder'\nexport { default as DataTable } from './models/data_table'\nexport { default as TestCaseHookDefinition } from './models/test_case_hook_definition'\nexport { version } from './version'\n\n// Formatters\nexport { default as Formatter, IFormatterOptions } from './formatter'\nexport { default as FormatterBuilder } from './formatter/builder'\nexport { default as JsonFormatter } from './formatter/json_formatter'\nexport { default as ProgressFormatter } from './formatter/progress_formatter'\nexport { default as RerunFormatter } from './formatter/rerun_formatter'\nexport { default as SnippetsFormatter } from './formatter/snippets_formatter'\nexport { default as SummaryFormatter } from './formatter/summary_formatter'\nexport { default as UsageFormatter } from './formatter/usage_formatter'\nexport { default as UsageJsonFormatter } from './formatter/usage_json_formatter'\nexport { formatterHelpers }\n\n// Support Code Functions\nconst { methods } = supportCodeLibraryBuilder\nexport const After = methods.After\nexport const AfterAll = methods.AfterAll\nexport const AfterStep = methods.AfterStep\nexport const Before = methods.Before\nexport const BeforeAll = methods.BeforeAll\nexport const BeforeStep = methods.BeforeStep\nexport const defineStep = methods.defineStep\nexport const defineParameterType = methods.defineParameterType\nexport const Given = methods.Given\nexport const setDefaultTimeout = methods.setDefaultTimeout\nexport const setDefinitionFunctionWrapper = methods.setDefinitionFunctionWrapper\nexport const setWorldConstructor = methods.setWorldConstructor\nexport const setParallelCanAssign = methods.setParallelCanAssign\nexport const Then = methods.Then\nexport const When = methods.When\nexport {\n default as World,\n IWorld,\n IWorldOptions,\n} from './support_code_library_builder/world'\nexport { parallelCanAssignHelpers }\n\nexport {\n ITestCaseHookParameter,\n ITestStepHookParameter,\n} from './support_code_library_builder/types'\nexport const Status = messages.TestStepResultStatus\n\n// Time helpers\nexport { wrapPromiseWithTimeout } from './time'\n\n// Deprecated\n/**\n * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const Cli = deprecate(\n _Cli,\n '`Cli` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const parseGherkinMessageStream = deprecate(\n cliHelpers.parseGherkinMessageStream,\n '`parseGherkinMessageStream` is deprecated, use `loadSources` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `loadSources` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const PickleFilter = deprecate(\n _PickleFilter,\n '`PickleFilter` is deprecated, use `loadSources` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\n/**\n * @deprecated use `runCucumber` instead; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\nexport const Runtime = deprecate(\n _Runtime,\n '`Runtime` is deprecated, use `runCucumber` instead; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n)\nexport { INewRuntimeOptions, IRuntimeOptions } from './runtime'\n"]}
package/lib/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const version = "8.11.1";
1
+ export declare const version = "9.0.1";
package/lib/version.js CHANGED
@@ -2,5 +2,5 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.version = void 0;
4
4
  // Generated by genversion.
5
- exports.version = '8.11.1';
5
+ exports.version = '9.0.1';
6
6
  //# sourceMappingURL=version.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":";;;AAAA,2BAA2B;AACd,QAAA,OAAO,GAAG,QAAQ,CAAA","sourcesContent":["// Generated by genversion.\nexport const version = '8.11.1'\n"]}
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":";;;AAAA,2BAA2B;AACd,QAAA,OAAO,GAAG,OAAO,CAAA","sourcesContent":["// Generated by genversion.\nexport const version = '9.0.1'\n"]}
package/lib/wrapper.mjs CHANGED
@@ -23,10 +23,12 @@ export const AfterStep = cucumber.AfterStep
23
23
  export const Before = cucumber.Before
24
24
  export const BeforeAll = cucumber.BeforeAll
25
25
  export const BeforeStep = cucumber.BeforeStep
26
+ export const defineStep = cucumber.defineStep
26
27
  export const defineParameterType = cucumber.defineParameterType
27
28
  export const Given = cucumber.Given
28
29
  export const setDefaultTimeout = cucumber.setDefaultTimeout
29
- export const setDefinitionFunctionWrapper = cucumber.setDefinitionFunctionWrapper
30
+ export const setDefinitionFunctionWrapper =
31
+ cucumber.setDefinitionFunctionWrapper
30
32
  export const setWorldConstructor = cucumber.setWorldConstructor
31
33
  export const Then = cucumber.Then
32
34
  export const When = cucumber.When
@@ -37,7 +39,6 @@ export const wrapPromiseWithTimeout = cucumber.wrapPromiseWithTimeout
37
39
 
38
40
  // Deprecated
39
41
  export const Cli = cucumber.Cli
40
- export const defineStep = cucumber.defineStep
41
42
  export const parseGherkinMessageStream = cucumber.parseGherkinMessageStream
42
43
  export const PickleFilter = cucumber.PickleFilter
43
44
  export const Runtime = cucumber.Runtime
package/package.json CHANGED
@@ -8,7 +8,7 @@
8
8
  "gherkin",
9
9
  "tests"
10
10
  ],
11
- "version": "8.11.1",
11
+ "version": "9.0.1",
12
12
  "homepage": "https://github.com/cucumber/cucumber-js",
13
13
  "author": "Julien Biezemans <jb@jbpros.com>",
14
14
  "contributors": [
@@ -46,6 +46,7 @@
46
46
  "Diego Di Mauro <hurrikam@users.noreply.github.com>",
47
47
  "Dmitry Shirokov <deadrunk@gmail.com>",
48
48
  "Dmytro Shpakovskyi <Marketionist@users.noreply.github.com>",
49
+ "Douglas Eggleton (https://github.com/douglaseggleton)",
49
50
  "Eddie Loeffen <eddieloeffen@gmail.com>",
50
51
  "efokschaner <eddyaod@gmail.com>",
51
52
  "Elwyn <elwyn@L1.co.nz>",
@@ -64,7 +65,9 @@
64
65
  "Izhaki <roey@gefri.org>",
65
66
  "Jan Molak <jan.molak@smartcodeltd.co.uk>",
66
67
  "Jan-Eric Duden <jeduden@gmail.com>",
68
+ "Jaryk (https://github.com/Ugzuzg)",
67
69
  "Jayson Smith <github@nes.33mail.com>",
70
+ "Jeff Tian (https://github.com/Jeff-Tian)",
68
71
  "Jesse Harlin <harlinjesse@gmail.com>",
69
72
  "João Guilherme Farias Duda <jgfd@cin.ufpe.br>",
70
73
  "Joaquín Sorianello <joac@users.noreply.github.com>",
@@ -82,6 +85,7 @@
82
85
  "Julian <JuloWaks@users.noreply.github.com>",
83
86
  "Julian <microweb10@gmail.com>",
84
87
  "Julien Biezemans <jb@jbpros.com>",
88
+ "Julien Gonzalez (https://github.com/customcommander)",
85
89
  "Karine Pires <karine.pires@alterway.fr>",
86
90
  "Kārlis Amoliņš <karlis.amolins.5@gmail.com>",
87
91
  "Karthik Viswanath <karthik.viswanath-contractor@adp.com>",
@@ -94,6 +98,7 @@
94
98
  "Kushal Pisavadia",
95
99
  "Kyle Moore <kyledmoore@gmail.com>",
96
100
  "Leonardo <mondloslp@gmail.com>",
101
+ "Long Nguyen (https://github.com/zcmgyu)",
97
102
  "lopesc <lopesc@users.noreply.github.com>",
98
103
  "Lucas Cimon <lucas.cimon@gmail.com>",
99
104
  "Ludek",
@@ -110,9 +115,11 @@
110
115
  "Martin Delille <martin@phonations.com>",
111
116
  "Máté Karácsony <k_mate@inf.elte.hu>",
112
117
  "Mateusz Derks <mateusz.derks@schibsted.pl>",
118
+ "Matt Travi (https://github.com/travi)",
113
119
  "Matteo Collina <matteo.collina@gmail.com>",
114
120
  "Maxim Koretskiy <mr.green.tv@gmail.com>",
115
121
  "mgonnet <gonnet.matias@gmail.com>",
122
+ "Michael Lloyd Morris (https://github.com/michael-lloyd-morris)",
116
123
  "Michael Zedeler <michael@zedeler.dk>",
117
124
  "Miika Hänninen <miika.hanninen@gmail.com>",
118
125
  "nebehr <thorgeir@tut.by>",
@@ -120,6 +127,7 @@
120
127
  "Niklas Närhinen <niklas@narhinen.net>",
121
128
  "Niyaz Akhmetov <axmet180@gmail.com>",
122
129
  "Noah Davis <noahd1@yahoo.com>",
130
+ "Oliver Odo (https://github.com/olivierodo)",
123
131
  "Oliver Rogers <oli.rogers@gmail.com>",
124
132
  "Olivier Melcher <olivier.melcher@gmail.com>",
125
133
  "Olle Jonsson <olle.jonsson@gmail.com>",
@@ -129,10 +137,12 @@
129
137
  "please-rewrite <please-rewrite@users.noreply.github.com>",
130
138
  "plocket <plocket@users.noreply.github.com>",
131
139
  "Renier Morales <renier@morales-rodriguez.net>",
140
+ "Ricardo Albuquerque (https://github.com/ricalbuquerque)",
132
141
  "Rick Lee-Morlang <rick@lee-morlang.com>",
133
142
  "RolandArgos <roland.ormrod@argos.co.uk>",
143
+ "Ronald Chen (https://github.com/Pyrolistical)",
134
144
  "Sam Saccone <sam@samx.it>",
135
- "Scott Deakin <scott.deakin@kantar.com>",
145
+ "Scott Deakin (https://github.com/GeekyDeaks)",
136
146
  "seantdg <sm.davis@gmx.com>",
137
147
  "Seb Rose <seb@claysnow.co.uk>",
138
148
  "Sérgio Junior <sergioamjr91@gmail.com>",
@@ -190,10 +200,10 @@
190
200
  },
191
201
  "types": "./lib/index.d.ts",
192
202
  "engines": {
193
- "node": "12 || 14 || >=16"
203
+ "node": "14 || 16 || >=18"
194
204
  },
195
205
  "enginesTested": {
196
- "node": "12 || 14 || 16 || 17 || 18 || 19"
206
+ "node": "14 || 16 || 18 || 19"
197
207
  },
198
208
  "dependencies": {
199
209
  "@cucumber/ci-environment": "9.1.0",
@@ -209,7 +219,7 @@
209
219
  "capital-case": "^1.0.4",
210
220
  "chalk": "^4.1.2",
211
221
  "cli-table3": "0.6.3",
212
- "commander": "^9.0.0",
222
+ "commander": "^10.0.0",
213
223
  "debug": "^4.3.4",
214
224
  "error-stack-parser": "^2.1.4",
215
225
  "figures": "^3.2.0",
@@ -233,7 +243,7 @@
233
243
  "util-arity": "^1.1.0",
234
244
  "verror": "^1.10.0",
235
245
  "xmlbuilder": "^15.1.1",
236
- "yaml": "1.10.2",
246
+ "yaml": "2.2.1",
237
247
  "yup": "^0.32.11"
238
248
  },
239
249
  "devDependencies": {
@@ -276,7 +286,6 @@
276
286
  "eslint-config-prettier": "8.6.0",
277
287
  "eslint-plugin-import": "2.26.0",
278
288
  "eslint-plugin-node": "11.1.0",
279
- "eslint-plugin-prettier": "4.2.1",
280
289
  "eslint-plugin-standard": "4.1.0",
281
290
  "express": "4.18.2",
282
291
  "fs-extra": "10.1.0",
@@ -304,10 +313,12 @@
304
313
  "docs:ci": "api-extractor run --verbose",
305
314
  "docs:local": "api-extractor run --verbose --local && api-documenter markdown --input-folder ./tmp/api-extractor --output-folder ./docs/api",
306
315
  "feature-test": "node bin/cucumber.js",
307
- "lint-autofix": "eslint --fix \"{compatibility,example,features,scripts,src,test}/**/*.ts\"",
316
+ "lint-code-autofix": "eslint --fix \"{compatibility,example,features,scripts,src,test}/**/*.ts\"",
308
317
  "lint-code": "eslint \"{compatibility,example,features,scripts,src,test}/**/*.ts\"",
309
318
  "lint-dependencies": "dependency-lint",
310
- "lint": "npm run lint-code && npm run lint-dependencies",
319
+ "lint-format-autofix": "prettier --write .",
320
+ "lint-format": "prettier --check .",
321
+ "lint": "npm run lint-code && npm run lint-format && npm run lint-dependencies",
311
322
  "prelint-autofix": "npm run build-local",
312
323
  "prelint-code": "npm run build-local",
313
324
  "precck-test": "npm run build-local",