open_api_import 0.8.5 → 0.8.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/open_api_import.rb +5 -5
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d9329d2ad9ddbbed9c5fd83c1953b04aab426610c398da4535617ab6c779090b
4
- data.tar.gz: aa17976853d624186f850c70a857b877b1faaba26cb94e1e8fc3fb34424ea1d8
3
+ metadata.gz: 9831061a87bf45ef15ba6d5f11ba63dd2b3cc15676b02d2d743f9ffba18bc0f0
4
+ data.tar.gz: 960ef6cb112bba14cdf0137d06bbe3065063860fbd15031e3f017a8c310eeb83
5
5
  SHA512:
6
- metadata.gz: ede975b9d25dee93fb70cfeaa38433e7d8602a9efd42d32259667ce989f0990eda9e7f4f749a8b1b9da2c642b89244a615946912cc97cc7bc47467933984b691
7
- data.tar.gz: 507693fc852a6b9be21dfab4f63a8179d3838a774125074fe820b1b4b3c6d386376f9f4d042e0a6ae1677b1701cca4c12eb3e08ce04c7ef651fe3088d5433b1c
6
+ metadata.gz: a3802042bacd6cc83f34767378bb34fa21c1283499d81acbae4ed5bf0eba79f18a4145c2c9e970aa58e72903ffcaff0ce5aaf296308f0d7b0b161132d55fdd4b
7
+ data.tar.gz: 97d322690e9e0653ac96d112a99f16288bead5b20a6947f249bc031a942022d8fc12a6a56f1d4b1cf95925d9dd79f4eaaf6f44d82c72b043b92cdfda2c1b9142
@@ -751,7 +751,7 @@ class OpenApiImport
751
751
  response_example.each do |rs|
752
752
  #(@type Google) for the case in example the key is something like: @type:
753
753
  if rs.match?(/^\s*@\w+:/)
754
- rs.gsub!(/@(\w+):/,"'@\1':")
754
+ rs.gsub!(/@(\w+):/,'\'@\1\':')
755
755
  end
756
756
  end
757
757
  return response_example
@@ -813,13 +813,13 @@ class OpenApiImport
813
813
  data_pattern << "#{dpk}: /#{dpv[:pattern].to_s}/"
814
814
  end
815
815
  elsif dpv.key?(:minLength) and dpv.key?(:maxLength)
816
- data_pattern << "#{dpk}: :'#{dpv[:minLength]}-#{dpv[:maxLength]}:TN'"
816
+ data_pattern << "#{dpk}: :'#{dpv[:minLength]}-#{dpv[:maxLength]}:LN$'"
817
817
  elsif dpv.key?(:minLength) and !dpv.key?(:maxLength)
818
- data_pattern << "#{dpk}: :'#{dpv[:minLength]}:TN'"
818
+ data_pattern << "#{dpk}: :'#{dpv[:minLength]}:LN$'"
819
819
  elsif !dpv.key?(:minLength) and dpv.key?(:maxLength)
820
- data_pattern << "#{dpk}: :'0-#{dpv[:maxLength]}:TN'"
820
+ data_pattern << "#{dpk}: :'0-#{dpv[:maxLength]}:LN$'"
821
821
  elsif dpv.key?(:minimum) and dpv.key?(:maximum) and dpv[:type]=='string'
822
- data_pattern << "#{dpk}: :'#{dpv[:minimum]}-#{dpv[:maximum]}:TN'"
822
+ data_pattern << "#{dpk}: :'#{dpv[:minimum]}-#{dpv[:maximum]}:LN$'"
823
823
  elsif dpv.key?(:minimum) and dpv.key?(:maximum)
824
824
  data_pattern << "#{dpk}: #{dpv[:minimum]}..#{dpv[:maximum]}"
825
825
  elsif dpv.key?(:minimum) and !dpv.key?(:maximum)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: open_api_import
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.5
4
+ version: 0.8.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mario Ruiz