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

gherkin/java: Support reading directly from input #2018

Merged
merged 8 commits into from
Oct 6, 2022

Conversation

mpkorstanje
Copy link
Contributor

@mpkorstanje mpkorstanje commented Jun 22, 2022

Summary

Support reading directly from input such a paths and input streams.

This also requires parsing the #encoding: pragma in feature files.
This is not a standard gherkin feature, but it better done here then in
Cucumber-JVM.

Added a `parseGherkinPlain` method to the parser make the readme less ugly.
@mpkorstanje mpkorstanje changed the title gherkin/java: Fix example in readme gherkin/java: Support reading directly from input Oct 6, 2022
This also requires parsing the #encoding: <encoding> pragma in feature files.
This is not a standard gherkin feature, but it better done here then in
Cucumber-JVM.
Added a `parseGherkinPlain` method to the parser make the readme less ugly.
@mpkorstanje mpkorstanje merged commit 85c6661 into main Oct 6, 2022
@mpkorstanje mpkorstanje deleted the fix-gherkin-docs-java branch October 6, 2022 15:33
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 11, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 11, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 11, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 12, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 12, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
mpkorstanje added a commit to cucumber/cucumber-jvm that referenced this pull request Oct 12, 2022
Previously before handing over a feature file to the Gherkin parser, Cucumber
would remove any Byte Order Markers (BOM) and determine the encoding of the
feature file based on the `#encoding: <encoding>` comment.

With cucumber/common#2018 this can now be handled by
Gherkin. Removing it simplifies Cucumber a little. Unfortunately the
`FeatureParser` doesn't take a `InputStream` as an argument. So we need to add
a default interface to avoid breaking semver.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant