Sha256: 97fbf1648c7096df0d1916ff13226002e7fe1cf96ca7dd37fe7ad42c7c309d3a

Contents?: true

Size: 1 KB

Versions: 4

Compression:

Stored size: 1 KB

Contents

Feature: Too Many Tags
  As a Business Analyst
  I want that scenarios are not tagged by too many tags
  so that readers can concentrate on the content of the scenario

  Background: Prepare Testee
    Given a file named "lint.rb" with:
      """
      $LOAD_PATH << '../../lib'
      require 'gherkin_lint'

      linter = GherkinLint::GherkinLint.new
      linter.enable %w(TooManyTags)
      linter.set_linter
      linter.analyze 'lint.feature'
      exit linter.report

      """

  Scenario: Many Tags
    Given a file named "lint.feature" with:
      """
      @A
      Feature: Test
        @B @C
        Scenario: A
      """
    When I run `ruby lint.rb`
    Then it should fail with exactly:
      """
      TooManyTags - Used 3 Tags
        lint.feature (4): Test.A

      """

  Scenario: Valid Example
    Given a file named "lint.feature" with:
      """
      @A
      Feature: Test
        @B
        Scenario: A
      """
    When I run `ruby lint.rb`
    Then it should pass with exactly:
      """
      """

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
gherkin_lint-1.2.2 features/too_many_tags.feature
gherkin_lint-1.2.1 features/too_many_tags.feature
gherkin_lint-1.1.0 features/too_many_tags.feature
gherkin_lint-1.0.0 features/too_many_tags.feature