Skip to content

Commit

Permalink
chore(lint): lint and format fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jonsamwell committed May 2, 2021
1 parent 98498e6 commit 5f0ccbd
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## [2.0.1] - 15/04/2021
## [2.0.1] - 02/05/2021

* BREAKING CHANGE: `TestFailure` is no longer thrown when an `expect` fails. Instead, use `GherkinTestFailure` when catching errors (i.e. replace `on TestFailure catch` with `on GherkinTestFailure catch`) (#37).

Expand Down
2 changes: 1 addition & 1 deletion example/report.json

Large diffs are not rendered by default.

8 changes: 0 additions & 8 deletions lib/src/configuration.dart
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,6 @@ class TestConfiguration {
// Lists feature files paths, which match [features] patterns.
FeatureFileMatcher featureFileMatcher = const IoFeatureFileAccessor();

@Deprecated('Use featureFileMatcher instead')
FeatureFileMatcher get featureFileIndexer => featureFileMatcher;

@Deprecated('Use featureFileMatcher instead')
set featureFileIndexer(FeatureFileMatcher matcher) {
featureFileMatcher = matcher;
}

// The feature file reader.
// Takes files/resources paths from [featureFileIndexer] and returns their content as String.
FeatureFileReader featureFileReader = const IoFeatureFileAccessor();
Expand Down
4 changes: 3 additions & 1 deletion lib/src/gherkin/syntax/background_syntax.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ class BackgroundSyntax extends RegExMatchedGherkinSyntax {
RegExp pattern(GherkinDialect dialect) {
final dialectPattern =
RegExMatchedGherkinSyntax.getMultiDialectRegexPattern(
dialect.background);
dialect.background,
);

return RegExp(
'^\\s*$dialectPattern:(\\s*(.+)\\s*)?',
multiLine: false,
Expand Down
1 change: 1 addition & 0 deletions lib/src/gherkin/syntax/example_syntax.dart
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ class ExampleSyntax extends RegExMatchedGherkinSyntax {
RegExp pattern(GherkinDialect dialect) {
final dialectPattern =
RegExMatchedGherkinSyntax.getMultiDialectRegexPattern(dialect.examples);

return RegExp(
'^\\s*(?:$dialectPattern):(\\s*(.+)\\s*)?\$',
multiLine: false,
Expand Down
1 change: 1 addition & 0 deletions lib/src/gherkin/syntax/scenario_syntax.dart
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ class ScenarioSyntax extends RegExMatchedGherkinSyntax<ScenarioRunnable> {
RegExp pattern(GherkinDialect dialect) {
final dialectPattern =
RegExMatchedGherkinSyntax.getMultiDialectRegexPattern(dialect.scenario);

return RegExp(
'^\\s*(?:$dialectPattern):\\s*(.+)\\s*\$',
multiLine: false,
Expand Down
3 changes: 2 additions & 1 deletion lib/src/gherkin/syntax/step_syntax.dart
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ class StepSyntax extends RegExMatchedGherkinSyntax<StepRunnable> {
RegExp pattern(GherkinDialect dialect) {
final dialectPattern =
RegExMatchedGherkinSyntax.getMultiDialectRegexPattern(
dialect.stepKeywords);
dialect.stepKeywords,
);

return RegExp(
'^($dialectPattern)\\s?.*',
Expand Down
7 changes: 5 additions & 2 deletions lib/src/gherkin/syntax/tag_syntax.dart
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ class TagSyntax extends RegExMatchedGherkinSyntax<TagsRunnable> {
AnnotatingBlock? annotating;

@override
RegExp pattern(GherkinDialect dialect) =>
RegExp('^@', multiLine: false, caseSensitive: false);
RegExp pattern(GherkinDialect dialect) => RegExp(
'^@',
multiLine: false,
caseSensitive: false,
);

@override
TagsRunnable toRunnable(
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: gherkin
version: 2.0.0
version: 2.0.1
description: A Gherkin parsers and runner for Dart which is very similar to Cucumber, it provides the base BDD functionality ready for use in platform specific implementations i.e. flutter/web
homepage: https://github.com/jonsamwell/dart_gherkin

Expand Down

0 comments on commit 5f0ccbd

Please sign in to comment.