idcf-json_hyper_schema 0.2.1 → 0.3.1

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
- SHA1:
3
- metadata.gz: 1e46dfb6cfc5842cfdaa1b52e26d6035c7a3ce11
4
- data.tar.gz: 54718f288e70ffdf1c173542a8211b2193bcad1a
2
+ SHA256:
3
+ metadata.gz: 778af3a591c0907016de4e26ebe4bb3c99f693ff71b6594cca326fbb1f389b49
4
+ data.tar.gz: b4593f756990f2fd2fbd4e40e131d6bdeed6eb58c7502bfea54e6af4389b448c
5
5
  SHA512:
6
- metadata.gz: c8ce892d827925310000a3ae4f674fc203b245517a270bd2e49ca01edf2dc43a9a9149b0f8b6a47f3e2efc631c0187d0ca446038088cbfe04b948c8452a04499
7
- data.tar.gz: 0bb77f19e9489fda26d0e4d2fcb13348cd9350286d7e81cb0cf06918e0b193cbbe345f6f94a92e7881567199ebcbb04df773c7ddf2ad230bba8968d9eece4f9c
6
+ metadata.gz: 9a7b759bfd65e94e3b1bfdaa631a32b3803119106790a4877f68533bc5d8fef92e3398198b2f0b9511513ec465d30077d0cf063feffcc430a27bf14a1e767de8
7
+ data.tar.gz: d5c363a29dea5ad76e16a0405eeb40916800bbedd4b30aeb1f4937a43637a41f35231bc3257ac48d5f85286554ab31b43e9f9a62daa478e17a0f9b7baa4c591c
@@ -14,6 +14,10 @@ engines:
14
14
  ratings:
15
15
  paths:
16
16
  - "**.rb"
17
+ checks:
18
+ method-complexity:
19
+ config:
20
+ threshold: 10
17
21
  exclude_paths:
18
22
  - vendor/bundle
19
23
  - .idea
data/.gitignore CHANGED
@@ -8,3 +8,4 @@
8
8
  *.iml
9
9
  .DS_Store
10
10
  .ruby-version
11
+ Gemfile.lock
data/.rspec ADDED
@@ -0,0 +1 @@
1
+ --require spec_helper
@@ -26,3 +26,5 @@ Style/ClassLength:
26
26
  Max: 150
27
27
  Style/MethodLength:
28
28
  Max: 15
29
+ Style/FormatStringToken:
30
+ Enabled: false
@@ -11,7 +11,7 @@ Gem::Specification.new do |spec|
11
11
 
12
12
  spec.summary = 'IDCF Json-Hyper-Schema Expand tools'
13
13
  spec.description = 'IDCF Json-Hyper-Schema Expand tools'
14
- spec.homepage = 'https://www.idcfcloud.jp'
14
+ spec.homepage = 'https://www.idcf.jp'
15
15
  spec.license = 'MIT'
16
16
 
17
17
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
@@ -21,11 +21,11 @@ Gem::Specification.new do |spec|
21
21
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
22
22
  spec.require_paths = ['lib']
23
23
 
24
- spec.add_development_dependency 'bundler', '~> 1.14'
25
- spec.add_development_dependency 'rake', '~> 10.0'
24
+ spec.add_development_dependency 'bundler', '>= 1.14'
25
+ spec.add_development_dependency 'rake', '>= 10.0'
26
26
  spec.add_development_dependency 'rspec'
27
27
 
28
- spec.add_dependency 'activerecord', '~> 4.2', '>= 4.2.3'
29
- spec.add_dependency 'activesupport', '~> 4.2', '>= 4.2.3'
28
+ spec.add_dependency 'activerecord', '>= 5.2.4.1'
29
+ spec.add_dependency 'activesupport', '>= 5.2.4.1'
30
30
  spec.add_dependency 'json_schema', '~> 0.17.0'
31
31
  end
@@ -41,7 +41,17 @@ module Idcf
41
41
  def expand(schema, options = {})
42
42
  return schema unless schema.class == Hash
43
43
  @process_version = schema_version(schema)
44
- result = expand_class.new(options)
44
+ # MEMO:
45
+ # Ruby2.7系では以下のような警告がでる
46
+ #
47
+ # Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call
48
+ #
49
+ # Ruby2.7系以上だけをサポートの対象とするなら場合分ける必要ないがそうではないので場合分けをしている。
50
+ if RUBY_VERSION >= '2.7'
51
+ result = expand_class.new(**options)
52
+ else
53
+ result = expand_class.new(options)
54
+ end
45
55
  result.do!(schema)
46
56
  result
47
57
  end
@@ -142,7 +142,7 @@ module Idcf
142
142
 
143
143
  def global_find(path)
144
144
  return nil unless path =~ /#.+/
145
- res = open(path)
145
+ res = URI.open(path)
146
146
  code, message = res.status
147
147
  raise "error: #{message}" unless code == '200'
148
148
 
@@ -1,5 +1,5 @@
1
1
  module Idcf
2
2
  module JsonHyperSchema
3
- VERSION = '0.2.1'.freeze
3
+ VERSION = '0.3.1'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,41 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: idcf-json_hyper_schema
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - IDC Frontier Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-04-15 00:00:00.000000000 Z
11
+ date: 2020-06-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.14'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.14'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  - !ruby/object:Gem::Dependency
@@ -56,42 +56,30 @@ dependencies:
56
56
  name: activerecord
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: '4.2'
62
59
  - - ">="
63
60
  - !ruby/object:Gem::Version
64
- version: 4.2.3
61
+ version: 5.2.4.1
65
62
  type: :runtime
66
63
  prerelease: false
67
64
  version_requirements: !ruby/object:Gem::Requirement
68
65
  requirements:
69
- - - "~>"
70
- - !ruby/object:Gem::Version
71
- version: '4.2'
72
66
  - - ">="
73
67
  - !ruby/object:Gem::Version
74
- version: 4.2.3
68
+ version: 5.2.4.1
75
69
  - !ruby/object:Gem::Dependency
76
70
  name: activesupport
77
71
  requirement: !ruby/object:Gem::Requirement
78
72
  requirements:
79
- - - "~>"
80
- - !ruby/object:Gem::Version
81
- version: '4.2'
82
73
  - - ">="
83
74
  - !ruby/object:Gem::Version
84
- version: 4.2.3
75
+ version: 5.2.4.1
85
76
  type: :runtime
86
77
  prerelease: false
87
78
  version_requirements: !ruby/object:Gem::Requirement
88
79
  requirements:
89
- - - "~>"
90
- - !ruby/object:Gem::Version
91
- version: '4.2'
92
80
  - - ">="
93
81
  - !ruby/object:Gem::Version
94
- version: 4.2.3
82
+ version: 5.2.4.1
95
83
  - !ruby/object:Gem::Dependency
96
84
  name: json_schema
97
85
  requirement: !ruby/object:Gem::Requirement
@@ -114,9 +102,9 @@ extra_rdoc_files: []
114
102
  files:
115
103
  - ".codeclimate.yml"
116
104
  - ".gitignore"
105
+ - ".rspec"
117
106
  - ".rubocop.yml"
118
107
  - Gemfile
119
- - Gemfile.lock
120
108
  - LICENSE.txt
121
109
  - README.md
122
110
  - Rakefile
@@ -130,7 +118,7 @@ files:
130
118
  - lib/idcf/json_hyper_schema/expands/v4.rb
131
119
  - lib/idcf/json_hyper_schema/validation.rb
132
120
  - lib/idcf/json_hyper_schema/version.rb
133
- homepage: https://www.idcfcloud.jp
121
+ homepage: https://www.idcf.jp
134
122
  licenses:
135
123
  - MIT
136
124
  metadata: {}
@@ -149,8 +137,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
149
137
  - !ruby/object:Gem::Version
150
138
  version: '0'
151
139
  requirements: []
152
- rubyforge_project:
153
- rubygems_version: 2.4.5.1
140
+ rubygems_version: 3.1.4
154
141
  signing_key:
155
142
  specification_version: 4
156
143
  summary: IDCF Json-Hyper-Schema Expand tools
@@ -1,60 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- idcf-json_hyper_schema (0.2.1)
5
- activerecord (~> 4.2, >= 4.2.3)
6
- activesupport (~> 4.2, >= 4.2.3)
7
- json_schema (~> 0.17.0)
8
-
9
- GEM
10
- remote: https://rubygems.org/
11
- specs:
12
- activemodel (4.2.11.1)
13
- activesupport (= 4.2.11.1)
14
- builder (~> 3.1)
15
- activerecord (4.2.11.1)
16
- activemodel (= 4.2.11.1)
17
- activesupport (= 4.2.11.1)
18
- arel (~> 6.0)
19
- activesupport (4.2.11.1)
20
- i18n (~> 0.7)
21
- minitest (~> 5.1)
22
- thread_safe (~> 0.3, >= 0.3.4)
23
- tzinfo (~> 1.1)
24
- arel (6.0.4)
25
- builder (3.2.3)
26
- concurrent-ruby (1.1.5)
27
- diff-lcs (1.3)
28
- i18n (0.9.5)
29
- concurrent-ruby (~> 1.0)
30
- json_schema (0.17.2)
31
- minitest (5.11.3)
32
- rake (10.5.0)
33
- rspec (3.6.0)
34
- rspec-core (~> 3.6.0)
35
- rspec-expectations (~> 3.6.0)
36
- rspec-mocks (~> 3.6.0)
37
- rspec-core (3.6.0)
38
- rspec-support (~> 3.6.0)
39
- rspec-expectations (3.6.0)
40
- diff-lcs (>= 1.2.0, < 2.0)
41
- rspec-support (~> 3.6.0)
42
- rspec-mocks (3.6.0)
43
- diff-lcs (>= 1.2.0, < 2.0)
44
- rspec-support (~> 3.6.0)
45
- rspec-support (3.6.0)
46
- thread_safe (0.3.6)
47
- tzinfo (1.2.5)
48
- thread_safe (~> 0.1)
49
-
50
- PLATFORMS
51
- ruby
52
-
53
- DEPENDENCIES
54
- bundler (~> 1.14)
55
- idcf-json_hyper_schema!
56
- rake (~> 10.0)
57
- rspec
58
-
59
- BUNDLED WITH
60
- 1.16.1