Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Gherkin Linting #191

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

PedroDiez
Copy link
Collaborator

@PedroDiez PedroDiez commented Nov 12, 2024

What type of PR is this?

  • correction
  • enhancement/feature
  • tests

What this PR does / why we need it:

PR to enable Gherkin Linter as per Commonalities/PR#292.
Even it is ongoing PR, it is fine to incorporate into WG to have some preliminary linter rules

Which issue(s) this PR fixes:

Fixes #180

Special notes for reviewers:

Changes with regards to Commonalities/PR#292

  • Indentation (NOTE: reviewed test_definitions in other WGs and this makes sense)
    "Background" set to "2".
    "example" set to "6".

  • Disable "file-name" kebab-case checking as operationId is lowerCamelCase.

  • Specific for Carrier Billing: disable "validate" word in Feature as Carrier Billing has validatePayment operation

Changelog input

 Enable Gherkin linter for Test Definitions

Additional documentation

N/A

@PedroDiez PedroDiez self-assigned this Nov 12, 2024
@PedroDiez PedroDiez added enhancement New feature or request correction API specification needs correction labels Nov 12, 2024
@PedroDiez
Copy link
Collaborator Author

PedroDiez commented Nov 12, 2024

@rartych I do not know how to manage pending linter errors.

image

@PedroDiez
Copy link
Collaborator Author

Commit 9a46336 would be a workaround to fix "logical operators comparison" topic raised by linter configuration

cc @rartych @bigludo7 just in case no simple solution can be found at linter configuration level

@rartych
Copy link
Collaborator

rartych commented Nov 14, 2024

It looks that angle brackets <,> are interpreted in Gherkin as as delimiters of example variables only. (cf. cucumber/common#1004 )
As it was iterpreted that way by the linter it may be interpreted the same way when generating executable tests.
I support the proposed above solution.

@PedroDiez
Copy link
Collaborator Author

It looks that angle brackets <,> are interpreted in Gherkin as as delimiters of example variables only. (cf. cucumber/common#1004 ) As it was iterpreted that way by the linter it may be interpreted the same way when generating executable tests. I support the proposed above solution.

Thanks for the feedback and info Rafal. Yes I think we can move forward with proposed above solution

@PedroDiez
Copy link
Collaborator Author

@rartych, @bigludo7 I will wait some time in order to align with Commonalities/PR#292 when merged.

I think it be considered for MetaRelease Spring 25. And in case not finally merged, just merge this as part of WG work for MetaRelease Spring 25 as it works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
correction API specification needs correction enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Results of applying gherkinlint to the test definitions
2 participants