cuke_modeler 3.0.0 → 3.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 12a7bac33e0fe407f250239e15637b732497d9d106893ae9d08943bb2497821c
4
- data.tar.gz: 26e6cf550dfdec1f87109651d73c01f403a97235277497ea7dc09017448a9a7c
3
+ metadata.gz: 3287a6e2f6cc9ce0269ce039535fe37bbe9be5bc6251c170efd87bdfa6d25b5e
4
+ data.tar.gz: 9413347eaf273b881e62dd792a1a7110ccf30d89ee7ed1620ae53c882008310b
5
5
  SHA512:
6
- metadata.gz: 129e84d0e7d10a7b217c040d7f6cab3590096e76345f679f61a51b3833c0c771fbb2299d997fd319851042d4a40bb2990310112d7fa8836d260ff91107d760cd
7
- data.tar.gz: 7dd7f4ebd77a9c9b898f4f07fcd33fe1e9216205b9d745ce7da5cff54dc6ba5febe6ed129594287d2c006165ef08a9717c88710b5cae346d15fe98c3e90844fe
6
+ metadata.gz: cc3d0ee5ca02ca1b81fd3784e471488952c8e5fe88401ce12ea0e10360b32a667b80934db8480aeae7936463ddc9c04ff0a02702d88ef0eaf6957b69a16680c5
7
+ data.tar.gz: 4af05a8b47ab76911764ebef5f10524c525a8c88852193bd928ac868e779cb4244fa540f7978df08fa58af602e53f0b6db5fb515d216f40117e58f939d49f8c9
@@ -8,6 +8,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
8
8
 
9
9
  Nothing yet...
10
10
 
11
+ ## [3.1.0] - 2020-06-28
12
+
13
+ ### Added
14
+ - Support added for more versions of the `cucumber-gherkin` gem
15
+ - 14.x
16
+
17
+ ### Fixed
18
+ - Text is converted to UTF-8 encoding before being passed to the underlying Gherkin gem. This is due to UTF-8 being
19
+ the only encoding supported by Gherkin. The `gherkin` gem did the conversion automatically but the `cucumber-gherkin`
20
+ gem does not.
21
+
11
22
  ## [3.0.0] - 2020-06-08
12
23
 
13
24
  ### Changed
@@ -303,7 +314,8 @@ Nothing yet...
303
314
  - Initial release
304
315
 
305
316
 
306
- [Unreleased]: https://github.com/enkessler/cuke_modeler/compare/v3.0.0...HEAD
317
+ [Unreleased]: https://github.com/enkessler/cuke_modeler/compare/v3.1.0...HEAD
318
+ [3.1.0]: https://github.com/enkessler/cuke_modeler/compare/v3.0.0...v3.1.0
307
319
  [3.0.0]: https://github.com/enkessler/cuke_modeler/compare/v2.1.0...v3.0.0
308
320
  [2.1.0]: https://github.com/enkessler/cuke_modeler/compare/v2.0.0...v2.1.0
309
321
  [2.0.0]: https://github.com/enkessler/cuke_modeler/compare/v1.5.1...v2.0.0
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
24
24
 
25
25
  spec.required_ruby_version = '>= 2.3', '< 3.0'
26
26
 
27
- spec.add_runtime_dependency 'cucumber-gherkin', '< 14.0'
27
+ spec.add_runtime_dependency 'cucumber-gherkin', '< 15.0'
28
28
 
29
29
  spec.add_development_dependency 'bundler', '< 3.0'
30
30
  spec.add_development_dependency "rake", '< 13.0.0'
@@ -0,0 +1,12 @@
1
+ require_relative 'gherkin_9_adapter'
2
+
3
+
4
+ module CukeModeler
5
+
6
+ # NOT A PART OF THE PUBLIC API
7
+ # An adapter that can convert the output of version 14.x of the *cucumber-gherkin* gem into input that is consumable by this gem.
8
+
9
+ class Gherkin14Adapter < Gherkin9Adapter
10
+
11
+ end
12
+ end
@@ -17,7 +17,7 @@ gherkin_version = Gem.loaded_specs['cucumber-gherkin'].version.version
17
17
  gherkin_major_version = gherkin_version.match(/^(\d+)\./)[1].to_i
18
18
 
19
19
  case gherkin_major_version
20
- when 9, 10, 11, 12, 13
20
+ when 9, 10, 11, 12, 13, 14
21
21
  # Currently nothing else to load beyond the entry point to the gem
22
22
  else
23
23
  raise("Unknown Gherkin version: '#{gherkin_version}'")
@@ -59,7 +59,7 @@ module CukeModeler
59
59
  raise(ArgumentError, "Text to parse must be a String but got #{source_text.class}") unless source_text.is_a?(String)
60
60
 
61
61
  begin
62
- parsed_result = parsing_method(source_text, filename)
62
+ parsed_result = parsing_method(source_text.encode('UTF-8'), filename)
63
63
  rescue => e
64
64
  raise(ArgumentError, "Error encountered while parsing '#{filename}'\n#{e.class} - #{e.message}")
65
65
  end
@@ -72,7 +72,7 @@ module CukeModeler
72
72
  gherkin_major_version = gherkin_version.match(/^(\d+)\./)[1].to_i
73
73
 
74
74
  case gherkin_major_version
75
- when 13
75
+ when 13, 14
76
76
  # todo - make these methods private?
77
77
  # NOT A PART OF THE PUBLIC API
78
78
  # The method to use for parsing Gherkin text
@@ -1,4 +1,4 @@
1
1
  module CukeModeler
2
2
  # The gem version
3
- VERSION = '3.0.0'
3
+ VERSION = '3.1.0'
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cuke_modeler
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0
4
+ version: 3.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Kessler
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-08 00:00:00.000000000 Z
11
+ date: 2020-06-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cucumber-gherkin
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "<"
18
18
  - !ruby/object:Gem::Version
19
- version: '14.0'
19
+ version: '15.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "<"
25
25
  - !ruby/object:Gem::Version
26
- version: '14.0'
26
+ version: '15.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -172,6 +172,7 @@ files:
172
172
  - lib/cuke_modeler/adapters/gherkin_11_adapter.rb
173
173
  - lib/cuke_modeler/adapters/gherkin_12_adapter.rb
174
174
  - lib/cuke_modeler/adapters/gherkin_13_adapter.rb
175
+ - lib/cuke_modeler/adapters/gherkin_14_adapter.rb
175
176
  - lib/cuke_modeler/adapters/gherkin_9_adapter.rb
176
177
  - lib/cuke_modeler/containing.rb
177
178
  - lib/cuke_modeler/described.rb