@cucumber/cucumber 9.3.0 → 9.4.0
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/README.md +1 -3
- package/lib/api/load_configuration.js +1 -1
- package/lib/api/load_configuration.js.map +1 -1
- package/lib/cli/index.d.ts +0 -1
- package/lib/cli/index.js +0 -5
- package/lib/cli/index.js.map +1 -1
- package/lib/cli/run.js +0 -7
- package/lib/cli/run.js.map +1 -1
- package/lib/configuration/types.d.ts +3 -0
- package/lib/configuration/types.js.map +1 -1
- package/lib/configuration/validate_configuration.d.ts +2 -1
- package/lib/configuration/validate_configuration.js +4 -1
- package/lib/configuration/validate_configuration.js.map +1 -1
- package/lib/support_code_library_builder/sourced_parameter_type_registry.d.ts +1 -2
- package/lib/support_code_library_builder/sourced_parameter_type_registry.js.map +1 -1
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +1 -1
- package/lib/cli/publish_banner.d.ts +0 -2
- package/lib/cli/publish_banner.js +0 -33
- package/lib/cli/publish_banner.js.map +0 -1
package/README.md
CHANGED
|
@@ -13,10 +13,8 @@
|
|
|
13
13
|
[](https://coveralls.io/github/cucumber/cucumber-js?branch=master)
|
|
14
14
|
[](https://opencollective.com/cucumber)
|
|
15
15
|
[](https://opencollective.com/cucumber)
|
|
16
|
-
[](https://oselvar.com/github/cucumber/oselvar-github-metrics/main/cucumber/cucumber-js)
|
|
17
|
-
[](https://oselvar.com/github/cucumber/oselvar-github-metrics/main/cucumber/cucumber-js)
|
|
18
16
|
|
|
19
|
-
[Cucumber](https://cucumber
|
|
17
|
+
[Cucumber](https://github.com/cucumber) is a tool for running automated tests written in plain language. Because they're
|
|
20
18
|
written in plain language, they can be read by anyone on your team. Because they can be
|
|
21
19
|
read by anyone, you can use them to help improve communication, collaboration and trust on
|
|
22
20
|
your team.
|
|
@@ -30,7 +30,7 @@ async function loadConfiguration(options = {}, environment = {}) {
|
|
|
30
30
|
: {};
|
|
31
31
|
const original = (0, configuration_1.mergeConfigurations)(configuration_1.DEFAULT_CONFIGURATION, profileConfiguration, options.provided);
|
|
32
32
|
logger.debug('Resolved configuration:', original);
|
|
33
|
-
(0, validate_configuration_1.validateConfiguration)(original);
|
|
33
|
+
(0, validate_configuration_1.validateConfiguration)(original, logger);
|
|
34
34
|
const runnable = await (0, convert_configuration_1.convertConfiguration)(original, env);
|
|
35
35
|
return {
|
|
36
36
|
useConfiguration: original,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"load_configuration.js","sourceRoot":"","sources":["../../src/api/load_configuration.ts"],"names":[],"mappings":";;;AAKA,8DAAyD;AACzD,oDAIyB;AACzB,oFAA+E;AAC/E,mEAA8D;AAC9D,+CAAgD;AAEhD,qDAAgD;AAEhD;;;;;;GAMG;AACI,KAAK,UAAU,iBAAiB,CACrC,UAAqC,EAAE,EACvC,cAA+B,EAAE;;IAEjC,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,GAAG,IAAA,8BAAgB,EAAC,WAAW,CAAC,CAAA;IACjE,MAAM,MAAM,GAAY,IAAI,8BAAa,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;IACxD,MAAM,UAAU,GAAG,MAAA,OAAO,CAAC,IAAI,mCAAI,IAAA,wBAAU,EAAC,GAAG,CAAC,CAAA;IAClD,IAAI,UAAU,EAAE;QACd,MAAM,CAAC,KAAK,CAAC,sCAAsC,UAAU,GAAG,CAAC,CAAA;KAClE;SAAM;QACL,MAAM,CAAC,KAAK,CAAC,6BAA6B,CAAC,CAAA;KAC5C;IACD,MAAM,oBAAoB,GAAG,UAAU;QACrC,CAAC,CAAC,MAAM,IAAA,wBAAQ,EAAC,MAAM,EAAE,GAAG,EAAE,UAAU,EAAE,OAAO,CAAC,QAAQ,CAAC;QAC3D,CAAC,CAAC,EAAE,CAAA;IACN,MAAM,QAAQ,GAAG,IAAA,mCAAmB,EAClC,q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E,MAAM,CAAC,CAAA;IACvC,MAAM,QAAQ,GAAG,MAAM,IAAA,4CAAoB,EAAC,QAAQ,EAAE,GAAG,CAAC,CAAA;IAC1D,OAAO;QACL,gBAAgB,EAAE,QAAQ;QAC1B,gBAAgB,EAAE,QAAQ;KAC3B,CAAA;AACH,CAAC;AA3BD,8CA2BC","sourcesContent":["import {\n IRunEnvironment,\n IResolvedConfiguration,\n ILoadConfigurationOptions,\n} from './types'\nimport { locateFile } from '../configuration/locate_file'\nimport {\n DEFAULT_CONFIGURATION,\n fromFile,\n mergeConfigurations,\n} from '../configuration'\nimport { validateConfiguration } from '../configuration/validate_configuration'\nimport { convertConfiguration } from './convert_configuration'\nimport { mergeEnvironment } from './environment'\nimport { ILogger } from '../logger'\nimport { ConsoleLogger } from './console_logger'\n\n/**\n * Load user-authored configuration to be used in a test run.\n *\n * @public\n * @param options - Coordinates required to find configuration.\n * @param environment - Project environment.\n */\nexport async function loadConfiguration(\n options: ILoadConfigurationOptions = {},\n environment: IRunEnvironment = {}\n): Promise<IResolvedConfiguration> {\n const { cwd, stderr, env, debug } = mergeEnvironment(environment)\n const logger: ILogger = new ConsoleLogger(stderr, debug)\n const configFile = options.file ?? locateFile(cwd)\n if (configFile) {\n logger.debug(`Configuration will be loaded from \"${configFile}\"`)\n } else {\n logger.debug('No configuration file found')\n }\n const profileConfiguration = configFile\n ? await fromFile(logger, cwd, configFile, options.profiles)\n : {}\n const original = mergeConfigurations(\n DEFAULT_CONFIGURATION,\n profileConfiguration,\n options.provided\n )\n logger.debug('Resolved configuration:', original)\n validateConfiguration(original, logger)\n const runnable = await convertConfiguration(original, env)\n return {\n useConfiguration: original,\n runConfiguration: runnable,\n }\n}\n"]}
|
package/lib/cli/index.d.ts
CHANGED
package/lib/cli/index.js
CHANGED
|
@@ -25,7 +25,6 @@ class Cli {
|
|
|
25
25
|
if (options.i18nLanguages) {
|
|
26
26
|
this.stdout.write((0, i18n_1.getLanguages)());
|
|
27
27
|
return {
|
|
28
|
-
shouldAdvertisePublish: false,
|
|
29
28
|
shouldExitImmediately: true,
|
|
30
29
|
success: true,
|
|
31
30
|
};
|
|
@@ -33,7 +32,6 @@ class Cli {
|
|
|
33
32
|
if (options.i18nKeywords) {
|
|
34
33
|
this.stdout.write((0, i18n_1.getKeywords)(options.i18nKeywords));
|
|
35
34
|
return {
|
|
36
|
-
shouldAdvertisePublish: false,
|
|
37
35
|
shouldExitImmediately: true,
|
|
38
36
|
success: true,
|
|
39
37
|
};
|
|
@@ -52,9 +50,6 @@ class Cli {
|
|
|
52
50
|
}, environment);
|
|
53
51
|
const { success } = await (0, api_1.runCucumber)(runConfiguration, environment);
|
|
54
52
|
return {
|
|
55
|
-
shouldAdvertisePublish: !runConfiguration.formats.publish &&
|
|
56
|
-
!configuration.publishQuiet &&
|
|
57
|
-
!(0, configuration_1.isTruthyString)(this.env.CUCUMBER_PUBLISH_QUIET),
|
|
58
53
|
shouldExitImmediately: configuration.forceExit,
|
|
59
54
|
success,
|
|
60
55
|
};
|
package/lib/cli/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";;;;;AAAA,oDAA6C;AAE7C,gCAAuD;AACvD,iCAAkD;AAClD,2DAAqD;AACrD,kDAAyB;AAOzB,MAAqB,GAAG;IAOtB,YAAY,EACV,IAAI,EACJ,GAAG,EACH,MAAM,EACN,MAAM,GAAG,OAAO,CAAC,MAAM,EACvB,GAAG,GAOJ;QACC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAA;QAChB,IAAI,CAAC,GAAG,GAAG,GAAG,CAAA;QACd,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;QACpB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;QACpB,IAAI,CAAC,GAAG,GAAG,GAAG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EAAE,aAAa,CAAC,SAAS;YAC9C,OAAO;SACR,CAAA;IACH,CAAC;CACF;AAxED,sBAwEC","sourcesContent":["import { ArgvParser } from '../configuration'\nimport { IFormatterStream } from '../formatter'\nimport { loadConfiguration, runCucumber } from '../api'\nimport { getKeywords, getLanguages } from './i18n'\nimport { validateInstall } from './install_validator'\nimport debug from 'debug'\n\nexport interface ICliRunResult {\n shouldExitImmediately: boolean\n success: boolean\n}\n\nexport default class Cli {\n private readonly argv: string[]\n private readonly cwd: string\n private readonly stdout: IFormatterStream\n private readonly stderr: IFormatterStream\n private readonly env: NodeJS.ProcessEnv\n\n constructor({\n argv,\n cwd,\n stdout,\n stderr = process.stderr,\n env,\n }: {\n argv: string[]\n cwd: string\n stdout: IFormatterStream\n stderr?: IFormatterStream\n env: NodeJS.ProcessEnv\n }) {\n this.argv = argv\n this.cwd = cwd\n this.stdout = stdout\n this.stderr = stderr\n this.env = env\n }\n\n async run(): Promise<ICliRunResult> {\n const debugEnabled = debug.enabled('cucumber')\n if (debugEnabled) {\n await validateInstall()\n }\n const { options, configuration: argvConfiguration } = ArgvParser.parse(\n this.argv\n )\n if (options.i18nLanguages) {\n this.stdout.write(getLanguages())\n return {\n shouldExitImmediately: true,\n success: true,\n }\n }\n if (options.i18nKeywords) {\n this.stdout.write(getKeywords(options.i18nKeywords))\n return {\n shouldExitImmediately: true,\n success: true,\n }\n }\n\n const environment = {\n cwd: this.cwd,\n stdout: this.stdout,\n stderr: this.stderr,\n env: this.env,\n debug: debugEnabled,\n }\n const { useConfiguration: configuration, runConfiguration } =\n await loadConfiguration(\n {\n file: options.config,\n profiles: options.profile,\n provided: argvConfiguration,\n },\n environment\n )\n const { success } = await runCucumber(runConfiguration, environment)\n return {\n shouldExitImmediately: configuration.forceExit,\n success,\n }\n }\n}\n"]}
|
package/lib/cli/run.js
CHANGED
|
@@ -8,15 +8,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
8
8
|
* but other code abstracts those to remain composable and testable. */
|
|
9
9
|
const _1 = __importDefault(require("./"));
|
|
10
10
|
const verror_1 = __importDefault(require("verror"));
|
|
11
|
-
const publish_banner_1 = __importDefault(require("./publish_banner"));
|
|
12
11
|
const validate_node_engine_version_1 = require("./validate_node_engine_version");
|
|
13
12
|
function logErrorMessageAndExit(message) {
|
|
14
13
|
console.error(message);
|
|
15
14
|
process.exit(1);
|
|
16
15
|
}
|
|
17
|
-
function displayPublishAdvertisementBanner() {
|
|
18
|
-
console.error(publish_banner_1.default);
|
|
19
|
-
}
|
|
20
16
|
async function run() {
|
|
21
17
|
(0, validate_node_engine_version_1.validateNodeEngineVersion)(process.version, (error) => {
|
|
22
18
|
console.error(error);
|
|
@@ -36,9 +32,6 @@ async function run() {
|
|
|
36
32
|
catch (error) {
|
|
37
33
|
logErrorMessageAndExit(verror_1.default.fullStack(error));
|
|
38
34
|
}
|
|
39
|
-
if (result.shouldAdvertisePublish) {
|
|
40
|
-
displayPublishAdvertisementBanner();
|
|
41
|
-
}
|
|
42
35
|
const exitCode = result.success ? 0 : 1;
|
|
43
36
|
if (result.shouldExitImmediately) {
|
|
44
37
|
process.exit(exitCode);
|
package/lib/cli/run.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run.js","sourceRoot":"","sources":["../../src/cli/run.ts"],"names":[],"mappings":";;;;;AAAA,+BAA+B;AAC/B;uEACuE;AACvE,0CAAuC;AACvC,oDAA2B;AAC3B,
|
|
1
|
+
{"version":3,"file":"run.js","sourceRoot":"","sources":["../../src/cli/run.ts"],"names":[],"mappings":";;;;;AAAA,+BAA+B;AAC/B;uEACuE;AACvE,0CAAuC;AACvC,oDAA2B;AAC3B,iFAA0E;AAE1E,SAAS,sBAAsB,CAAC,OAAe;IAC7C,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,CAAA;IACtB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;AACjB,CAAC;AAEc,KAAK,UAAU,GAAG;IAC/B,IAAA,wDAAyB,EACvB,OAAO,CAAC,OAAO,EACf,CAAC,KAAK,EAAE,EAAE;QACR,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAA;QACpB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;IACjB,CAAC,EACD,OAAO,CAAC,IAAI,CACb,CAAA;IAED,MAAM,GAAG,GAAG,IAAI,UAAG,CAAC;QAClB,IAAI,EAAE,OAAO,CAAC,IAAI;QAClB,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE;QAClB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,GAAG,EAAE,OAAO,CAAC,GAAG;KACjB,CAAC,CAAA;IAEF,IAAI,MAAqB,CAAA;IACzB,IAAI;QACF,MAAM,GAAG,MAAM,GAAG,CAAC,GAAG,EAAE,CAAA;KACzB;IAAC,OAAO,KAAK,EAAE;QACd,sBAAsB,CAAC,gBAAM,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAA;KAChD;IAED,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IACvC,IAAI,MAAM,CAAC,qBAAqB,EAAE;QAChC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAA;KACvB;SAAM;QACL,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAA;KAC5B;AACH,CAAC;AA/BD,sBA+BC","sourcesContent":["/* eslint-disable no-console */\n/* This is one rare place where we're fine to use process/console directly,\n * but other code abstracts those to remain composable and testable. */\nimport Cli, { ICliRunResult } from './'\nimport VError from 'verror'\nimport { validateNodeEngineVersion } from './validate_node_engine_version'\n\nfunction logErrorMessageAndExit(message: string): void {\n console.error(message)\n process.exit(1)\n}\n\nexport default async function run(): Promise<void> {\n validateNodeEngineVersion(\n process.version,\n (error) => {\n console.error(error)\n process.exit(1)\n },\n console.warn\n )\n\n const cli = new Cli({\n argv: process.argv,\n cwd: process.cwd(),\n stdout: process.stdout,\n stderr: process.stderr,\n env: process.env,\n })\n\n let result: ICliRunResult\n try {\n result = await cli.run()\n } catch (error) {\n logErrorMessageAndExit(VError.fullStack(error))\n }\n\n const exitCode = result.success ? 0 : 1\n if (result.shouldExitImmediately) {\n process.exit(exitCode)\n } else {\n process.exitCode = exitCode\n }\n}\n"]}
|
|
@@ -14,6 +14,9 @@ export interface IConfiguration {
|
|
|
14
14
|
paths: string[];
|
|
15
15
|
parallel: number;
|
|
16
16
|
publish: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* @deprecated no longer needed; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>
|
|
19
|
+
*/
|
|
17
20
|
publishQuiet: boolean;
|
|
18
21
|
require: string[];
|
|
19
22
|
requireModule: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/configuration/types.ts"],"names":[],"mappings":"","sourcesContent":["import { FormatOptions } from '../formatter'\nimport { PickleOrder } from '../models/pickle_order'\n\nexport interface IConfiguration {\n backtrace: boolean\n dryRun: boolean\n forceExit: boolean\n failFast: boolean\n format: string[]\n formatOptions: FormatOptions\n import: string[]\n language: string\n name: string[]\n order: PickleOrder\n paths: string[]\n parallel: number\n publish: boolean\n publishQuiet: boolean\n require: string[]\n requireModule: string[]\n retry: number\n retryTagFilter: string\n strict: boolean\n tags: string\n worldParameters: any\n}\n"]}
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/configuration/types.ts"],"names":[],"mappings":"","sourcesContent":["import { FormatOptions } from '../formatter'\nimport { PickleOrder } from '../models/pickle_order'\n\nexport interface IConfiguration {\n backtrace: boolean\n dryRun: boolean\n forceExit: boolean\n failFast: boolean\n format: string[]\n formatOptions: FormatOptions\n import: string[]\n language: string\n name: string[]\n order: PickleOrder\n paths: string[]\n parallel: number\n publish: boolean\n /**\n * @deprecated no longer needed; see <https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md>\n */\n publishQuiet: boolean\n require: string[]\n requireModule: string[]\n retry: number\n retryTagFilter: string\n strict: boolean\n tags: string\n worldParameters: any\n}\n"]}
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.validateConfiguration = void 0;
|
|
4
|
-
function validateConfiguration(configuration) {
|
|
4
|
+
function validateConfiguration(configuration, logger) {
|
|
5
|
+
if (configuration.publishQuiet) {
|
|
6
|
+
logger.warn('`publishQuiet` option is no longer needed, you can remove it from your configuration; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md');
|
|
7
|
+
}
|
|
5
8
|
if (configuration.retryTagFilter && !configuration.retry) {
|
|
6
9
|
throw new Error('a positive `retry` count must be specified when setting `retryTagFilter`');
|
|
7
10
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate_configuration.js","sourceRoot":"","sources":["../../src/configuration/validate_configuration.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"validate_configuration.js","sourceRoot":"","sources":["../../src/configuration/validate_configuration.ts"],"names":[],"mappings":";;;AAGA,SAAgB,qBAAqB,CACnC,aAA6B,EAC7B,MAAe;IAEf,IAAI,aAAa,CAAC,YAAY,EAAE;QAC9B,MAAM,CAAC,IAAI,CACT,kKAAkK,CACnK,CAAA;KACF;IACD,IAAI,aAAa,CAAC,cAAc,IAAI,CAAC,aAAa,CAAC,KAAK,EAAE;QACxD,MAAM,IAAI,KAAK,CACb,0EAA0E,CAC3E,CAAA;KACF;AACH,CAAC;AAdD,sDAcC","sourcesContent":["import { IConfiguration } from './types'\nimport { ILogger } from '../logger'\n\nexport function validateConfiguration(\n configuration: IConfiguration,\n logger: ILogger\n): void {\n if (configuration.publishQuiet) {\n logger.warn(\n '`publishQuiet` option is no longer needed, you can remove it from your configuration; see https://github.com/cucumber/cucumber-js/blob/main/docs/deprecations.md'\n )\n }\n if (configuration.retryTagFilter && !configuration.retry) {\n throw new Error(\n 'a positive `retry` count must be specified when setting `retryTagFilter`'\n )\n }\n}\n"]}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { ParameterTypeRegistry } from '@cucumber/cucumber-expressions';
|
|
2
|
-
import ParameterType from '@cucumber/cucumber-expressions/dist/cjs/src/ParameterType';
|
|
1
|
+
import { ParameterType, ParameterTypeRegistry } from '@cucumber/cucumber-expressions';
|
|
3
2
|
import { ILineAndUri } from '../types';
|
|
4
3
|
export declare class SourcedParameterTypeRegistry extends ParameterTypeRegistry {
|
|
5
4
|
private parameterTypeToSource;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sourced_parameter_type_registry.js","sourceRoot":"","sources":["../../src/support_code_library_builder/sourced_parameter_type_registry.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"sourced_parameter_type_registry.js","sourceRoot":"","sources":["../../src/support_code_library_builder/sourced_parameter_type_registry.ts"],"names":[],"mappings":";;;AAAA,yEAGuC;AAGvC,MAAa,4BAA6B,SAAQ,4CAAqB;IAAvE;;QACU,0BAAqB,GAC3B,IAAI,OAAO,EAAE,CAAA;IAajB,CAAC;IAXC,0BAA0B,CACxB,aAAqC,EACrC,MAAmB;QAEnB,IAAI,CAAC,mBAAmB,CAAC,aAAa,CAAC,CAAA;QACvC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,aAAa,EAAE,MAAM,CAAC,CAAA;IACvD,CAAC;IAED,YAAY,CAAC,aAAqC;QAChD,OAAO,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,aAAa,CAAC,CAAA;IACtD,CAAC;CACF;AAfD,oEAeC","sourcesContent":["import {\n ParameterType,\n ParameterTypeRegistry,\n} from '@cucumber/cucumber-expressions'\nimport { ILineAndUri } from '../types'\n\nexport class SourcedParameterTypeRegistry extends ParameterTypeRegistry {\n private parameterTypeToSource: WeakMap<ParameterType<unknown>, ILineAndUri> =\n new WeakMap()\n\n defineSourcedParameterType(\n parameterType: ParameterType<unknown>,\n source: ILineAndUri\n ) {\n this.defineParameterType(parameterType)\n this.parameterTypeToSource.set(parameterType, source)\n }\n\n lookupSource(parameterType: ParameterType<unknown>) {\n return this.parameterTypeToSource.get(parameterType)\n }\n}\n"]}
|
package/lib/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "9.
|
|
1
|
+
export declare const version = "9.4.0";
|
package/lib/version.js
CHANGED
package/lib/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
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.
|
|
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.4.0'\n"]}
|
package/package.json
CHANGED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
7
|
-
const cli_table3_1 = __importDefault(require("cli-table3"));
|
|
8
|
-
const chalkInstance = chalk_1.default.stderr;
|
|
9
|
-
const underlineBoldCyan = (x) => chalkInstance.underline(chalkInstance.bold(chalkInstance.cyan(x)));
|
|
10
|
-
const formattedReportUrl = underlineBoldCyan('https://reports.cucumber.io');
|
|
11
|
-
const formattedEnv = chalkInstance.cyan('CUCUMBER_PUBLISH_ENABLED') +
|
|
12
|
-
'=' +
|
|
13
|
-
chalkInstance.cyan('true');
|
|
14
|
-
const formattedMoreInfoUrl = underlineBoldCyan('https://cucumber.io/docs/cucumber/environment-variables/');
|
|
15
|
-
const text = `\
|
|
16
|
-
Share your Cucumber Report with your team at ${formattedReportUrl}
|
|
17
|
-
|
|
18
|
-
Command line option: ${chalkInstance.cyan('--publish')}
|
|
19
|
-
Environment variable: ${formattedEnv}
|
|
20
|
-
|
|
21
|
-
More information at ${formattedMoreInfoUrl}
|
|
22
|
-
|
|
23
|
-
To disable this message, add this to your ${chalkInstance.bold('./cucumber.js')}:
|
|
24
|
-
${chalkInstance.bold("module.exports = { default: '--publish-quiet' }")}`;
|
|
25
|
-
const table = new cli_table3_1.default({
|
|
26
|
-
style: {
|
|
27
|
-
head: [],
|
|
28
|
-
border: chalkInstance.supportsColor ? ['green'] : [],
|
|
29
|
-
},
|
|
30
|
-
});
|
|
31
|
-
table.push([text]);
|
|
32
|
-
exports.default = table.toString();
|
|
33
|
-
//# sourceMappingURL=publish_banner.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"publish_banner.js","sourceRoot":"","sources":["../../src/cli/publish_banner.ts"],"names":[],"mappings":";;;;;AAAA,kDAAyB;AACzB,4DAA8B;AAE9B,MAAM,aAAa,GAAG,eAAK,CAAC,MAAM,CAAA;AAElC,MAAM,iBAAiB,GAAG,CAAC,CAAS,EAAU,EAAE,CAC9C,aAAa,CAAC,SAAS,CAAC,aAAa,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAEpE,MAAM,kBAAkB,GAAG,iBAAiB,CAAC,6BAA6B,CAAC,CAAA;AAC3E,MAAM,YAAY,GAChB,aAAa,CAAC,IAAI,CAAC,0BAA0B,CAAC;IAC9C,GAAG;IACH,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;AAC5B,MAAM,oBAAoB,GAAG,iBAAiB,CAC5C,0DAA0D,CAC3D,CAAA;AAED,MAAM,IAAI,GAAG;+CACkC,kBAAkB;;0BAEvC,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC;0BAC/B,YAAY;;sBAEhB,oBAAoB;;4CAEE,aAAa,CAAC,IAAI,CAC5D,eAAe,CAChB;EACC,aAAa,CAAC,IAAI,CAAC,iDAAiD,CAAC,EAAE,CAAA;AAEzE,MAAM,KAAK,GAAG,IAAI,oBAAK,CAAC;IACtB,KAAK,EAAE;QACL,IAAI,EAAE,EAAE;QACR,MAAM,EAAE,aAAa,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE;KACrD;CACF,CAAC,CAAA;AAEF,KAAK,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAA;AAElB,kBAAe,KAAK,CAAC,QAAQ,EAAE,CAAA","sourcesContent":["import chalk from 'chalk'\nimport Table from 'cli-table3'\n\nconst chalkInstance = chalk.stderr\n\nconst underlineBoldCyan = (x: string): string =>\n chalkInstance.underline(chalkInstance.bold(chalkInstance.cyan(x)))\n\nconst formattedReportUrl = underlineBoldCyan('https://reports.cucumber.io')\nconst formattedEnv =\n chalkInstance.cyan('CUCUMBER_PUBLISH_ENABLED') +\n '=' +\n chalkInstance.cyan('true')\nconst formattedMoreInfoUrl = underlineBoldCyan(\n 'https://cucumber.io/docs/cucumber/environment-variables/'\n)\n\nconst text = `\\\nShare your Cucumber Report with your team at ${formattedReportUrl}\n\nCommand line option: ${chalkInstance.cyan('--publish')}\nEnvironment variable: ${formattedEnv}\n\nMore information at ${formattedMoreInfoUrl}\n\nTo disable this message, add this to your ${chalkInstance.bold(\n './cucumber.js'\n)}: \n${chalkInstance.bold(\"module.exports = { default: '--publish-quiet' }\")}`\n\nconst table = new Table({\n style: {\n head: [],\n border: chalkInstance.supportsColor ? ['green'] : [],\n },\n})\n\ntable.push([text])\n\nexport default table.toString()\n"]}
|