diff --git a/CHANGELOG.md b/CHANGELOG.md index 5a1b3a092..00ec65b8f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ Please see [CONTRIBUTING.md](https://github.com/cucumber/cucumber/blob/master/CO ### Breaking changes * Drop support for Node.js 10 and 15, add support for Node.js 16 +* Remove deprecated `--retryTagFilter` option (the correct option is `--retry-tag-filter`) ### Added diff --git a/features/retry.feature b/features/retry.feature index 6cca5ccf5..6e114155c 100644 --- a/features/retry.feature +++ b/features/retry.feature @@ -12,27 +12,6 @@ Feature: Retry flaky tests """ And it fails - @spawn - Scenario: running Cucumber JS with --retryTagFilter in camel case will result in a warning - Given a file named "features/a.feature" with: - """ - Feature: - Scenario: - Given a step - """ - Given a file named "features/step_definitions/cucumber_steps.js" with: - """ - const {Given} = require('@cucumber/cucumber') - - Given(/^a step$/, function() {}) - """ - When I run cucumber-js with `--retry 1 --retryTagFilter @flaky` - Then the error output contains the text: - """ - the argument --retryTagFilter is deprecated and will be removed in a future release; please use --retry-tag-filter - """ - But it passes - Scenario: running Cucumber JS with negative --retry will fail When I run cucumber-js with `--retry -1` Then the error output contains the text: @@ -590,4 +569,4 @@ Feature: Retry flaky tests Then it fails And scenario "Failing" attempt 0 step "Given a failing step" has status "failed" And scenario "Failing" attempt 1 step "Given a failing step" has status "failed" - And scenario "Passing" step "Given a passing step" has status "skipped" \ No newline at end of file + And scenario "Passing" step "Given a passing step" has status "skipped" diff --git a/src/cli/argv_parser.ts b/src/cli/argv_parser.ts index 1a80381fc..7ab52e82c 100644 --- a/src/cli/argv_parser.ts +++ b/src/cli/argv_parser.ts @@ -200,7 +200,7 @@ const ArgvParser = { 0 ) .option( - '--retryTagFilter, --retry-tag-filter ', + '--retry-tag-filter ', `only retries the features or scenarios with tags matching the expression (repeatable). This option requires '--retry' to be specified.`, ArgvParser.mergeTags, @@ -236,14 +236,6 @@ const ArgvParser = { args: program.args, } }, - - lint(fullArgv: string[]): void { - if (fullArgv.includes('--retryTagFilter')) { - console.warn( - 'the argument --retryTagFilter is deprecated and will be removed in a future release; please use --retry-tag-filter' - ) - } - }, } export default ArgvParser diff --git a/src/cli/configuration_builder.ts b/src/cli/configuration_builder.ts index 7aa89dbf5..c1f9c5247 100644 --- a/src/cli/configuration_builder.ts +++ b/src/cli/configuration_builder.ts @@ -59,8 +59,6 @@ export default class ConfigurationBuilder { constructor({ argv, cwd }: INewConfigurationBuilderOptions) { this.cwd = cwd - - ArgvParser.lint(argv) const parsedArgv = ArgvParser.parse(argv) this.args = parsedArgv.args this.options = parsedArgv.options