gherkin_lint 0.4.2 → 0.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fa02cf051b9231b020ddef1d0814c9ee2acb9c60
4
- data.tar.gz: 9cef934f0410b54cbf8b3ee8b83fbcdc4b847027
3
+ metadata.gz: e0f116fd44427ce5038611445116ca21fa99ac8e
4
+ data.tar.gz: f7079da931ff4a343453a66087986bfbb27d362f
5
5
  SHA512:
6
- metadata.gz: 7e03d582589f9dace3801ae42ad3bffe49780b57e5646e26e871454c031ce7df71f8ad95703bae2f08e70a873f02ed69c31b360e5ba52bce6d3e2a6071535d37
7
- data.tar.gz: 71497f5f798f092865180b0cc0b1881436e5981990bf7b9ac4cdced45896dc3163fbca5600579dc3cf0d2389f5b936ac5b51d77f7317a020e249019f8729bf53
6
+ metadata.gz: 23d7c10e0e234fbfab755a5b0a938004ccba577df307ae52a6908a6b372a729bb42ad1c39b71395ed80a5eb48866a3ad64d244f212dae16ca48ff78a15836a53
7
+ data.tar.gz: 71172fa75faea3798950027a5649b3e73faa6dbe2591a90e8eb590ff8557fb72fb3db4388ae0f033afa40a01333f2483b5359edcf8ea7782f3f07239a7f25a7e
data/.rubocop.yml CHANGED
@@ -13,7 +13,7 @@ Metrics/AbcSize:
13
13
  # Offense count: 1
14
14
  # Configuration parameters: CountComments.
15
15
  Metrics/ClassLength:
16
- Max: 122
16
+ Max: 123
17
17
 
18
18
  # Offense count: 33
19
19
  # Configuration parameters: AllowHeredoc, AllowURI, URISchemes.
data/Rakefile CHANGED
@@ -11,7 +11,7 @@ end
11
11
 
12
12
  desc 'Publishes the Gem'
13
13
  task :push do
14
- sh 'gem push gherkin_lint-0.4.2.gem'
14
+ sh 'gem push gherkin_lint-0.4.3.gem'
15
15
  end
16
16
 
17
17
  desc 'Checks ruby style'
@@ -46,3 +46,15 @@ Feature: Missing Test Action
46
46
  """
47
47
 
48
48
  """
49
+
50
+ Scenario: Empty Scenario
51
+ Given a file named "lint.feature" with:
52
+ """
53
+ Feature: Test
54
+ Scenario: A
55
+ """
56
+ When I run `ruby lint.rb`
57
+ Then it should pass with exactly:
58
+ """
59
+
60
+ """
@@ -46,3 +46,15 @@ Feature: Missing Verification
46
46
  """
47
47
 
48
48
  """
49
+
50
+ Scenario: Empty Scenario
51
+ Given a file named "lint.feature" with:
52
+ """
53
+ Feature: Test
54
+ Scenario: A
55
+ """
56
+ When I run `ruby lint.rb`
57
+ Then it should pass with exactly:
58
+ """
59
+
60
+ """
@@ -40,6 +40,23 @@ Feature: Use Outline
40
40
 
41
41
  """
42
42
 
43
+ Scenario: Empty Scenarios
44
+ Given a file named "lint.feature" with:
45
+ """
46
+ Feature: Test
47
+ Background: Preparation
48
+ Given setup
49
+
50
+ Scenario: A
51
+
52
+ Scenario: B
53
+ """
54
+ When I run `ruby lint.rb`
55
+ Then it should pass with exactly:
56
+ """
57
+
58
+ """
59
+
43
60
  Scenario: Valid Example
44
61
  Given a file named "lint.feature" with:
45
62
  """
data/gherkin_lint.gemspec CHANGED
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'gherkin_lint'
3
- s.version = '0.4.2'
4
- s.date = '2016-08-19'
3
+ s.version = '0.4.3'
4
+ s.date = '2016-08-30'
5
5
  s.summary = 'Gherkin Lint'
6
6
  s.description = 'Lint Gherkin Files'
7
7
  s.authors = ['Stefan Rohe']
@@ -33,6 +33,7 @@ module GherkinLint
33
33
  def filled_scenarios
34
34
  scenarios do |file, feature, scenario|
35
35
  next unless scenario.include? :steps
36
+ next if scenario[:steps].empty?
36
37
  yield(file, feature, scenario)
37
38
  end
38
39
  end
@@ -32,6 +32,7 @@ module GherkinLint
32
32
  feature[:children].each do |scenario|
33
33
  next unless scenario[:type] == :Scenario
34
34
  next unless scenario.include? :steps
35
+ next if scenario[:steps].empty?
35
36
  scenarios.push generate_reference(file, feature, scenario)
36
37
  end
37
38
  scenarios
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gherkin_lint
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Rohe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-19 00:00:00.000000000 Z
11
+ date: 2016-08-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gherkin