strum-service 0.2.0 → 0.2.3

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: 5fb6ced97fb4ca360125eacaaf126b16cd20d1eaec11fa44da8e7343bcd6824b
4
- data.tar.gz: 18f2f7e2379143b136c5200320880c6592adb5968f16f15c6471b5da33a4737c
3
+ metadata.gz: ddd2f44e3603a86779ff7341bfcf30e15de6d7ddc70aec5182f031784fdaa25c
4
+ data.tar.gz: 686f27af81d9e2b72ed4d20321db076a6c54a3aa1df3867e24d20d370fc210e7
5
5
  SHA512:
6
- metadata.gz: dd0b7a43efc17cd92dc80748e94fc7339e14ebeb8c8c38b508d73b92fde28c3c77d6500df03c3a5493ddf388b53a8ea4b1500533b456ee3c9d4cd746d8f012a4
7
- data.tar.gz: a95e51946cb31f1424b621bb938e96da89f0e751bf3865585b027edb0235b6b358354ac4fdda2979bf1327d591f9ebff722657f17689beef78806dab11d7822e
6
+ metadata.gz: d1b6d52ec205a010c8a35e39ce6e38a44fb08ff62ffcd84b4ca633943d459d6b86285b8ef4a8691686f8a7bd8e05704eb60b968aa456a01f0b74b47bf172f708
7
+ data.tar.gz: a8a6d7d8c8a36aab1e7c3d52212a1b5c373d19758a92a81d5e34c1163a7ead0245723cb58f860a3efddc9013ab2ae44700a8ea7d1403c16e8952f77d5b2ab3b7
data/Gemfile CHANGED
@@ -7,8 +7,8 @@ gemspec
7
7
 
8
8
  gem "rake", "~> 12.0"
9
9
 
10
- gem "rspec", "~> 3.10"
11
- gem "rubocop", "~> 1.5"
12
- gem "rubocop-ast", "~> 1.3"
13
- gem "rubocop-rake", "~> 0.5.1"
14
- gem "rubocop-rspec", "~> 2.0.0"
10
+ gem "rspec", "~> 3.11.0"
11
+ gem "rubocop", "~> 1.25.1"
12
+ gem "rubocop-ast", "~> 1.16.0"
13
+ gem "rubocop-rake", "~> 0.6.0"
14
+ gem "rubocop-rspec", "~> 2.9.0"
data/Gemfile.lock CHANGED
@@ -1,63 +1,62 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- strum-service (0.2.0)
4
+ strum-service (0.2.3)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
8
8
  specs:
9
9
  ast (2.4.2)
10
- diff-lcs (1.4.4)
11
- parallel (1.20.1)
12
- parser (3.0.2.0)
10
+ diff-lcs (1.5.0)
11
+ parallel (1.21.0)
12
+ parser (3.1.1.0)
13
13
  ast (~> 2.4.1)
14
- rainbow (3.0.0)
14
+ rainbow (3.1.1)
15
15
  rake (12.3.3)
16
- regexp_parser (2.1.1)
16
+ regexp_parser (2.2.1)
17
17
  rexml (3.2.5)
18
- rspec (3.10.0)
19
- rspec-core (~> 3.10.0)
20
- rspec-expectations (~> 3.10.0)
21
- rspec-mocks (~> 3.10.0)
22
- rspec-core (3.10.1)
23
- rspec-support (~> 3.10.0)
24
- rspec-expectations (3.10.1)
18
+ rspec (3.11.0)
19
+ rspec-core (~> 3.11.0)
20
+ rspec-expectations (~> 3.11.0)
21
+ rspec-mocks (~> 3.11.0)
22
+ rspec-core (3.11.0)
23
+ rspec-support (~> 3.11.0)
24
+ rspec-expectations (3.11.0)
25
25
  diff-lcs (>= 1.2.0, < 2.0)
26
- rspec-support (~> 3.10.0)
27
- rspec-mocks (3.10.2)
26
+ rspec-support (~> 3.11.0)
27
+ rspec-mocks (3.11.0)
28
28
  diff-lcs (>= 1.2.0, < 2.0)
29
- rspec-support (~> 3.10.0)
30
- rspec-support (3.10.2)
31
- rubocop (1.18.4)
29
+ rspec-support (~> 3.11.0)
30
+ rspec-support (3.11.0)
31
+ rubocop (1.25.1)
32
32
  parallel (~> 1.10)
33
- parser (>= 3.0.0.0)
33
+ parser (>= 3.1.0.0)
34
34
  rainbow (>= 2.2.2, < 4.0)
35
35
  regexp_parser (>= 1.8, < 3.0)
36
36
  rexml
37
- rubocop-ast (>= 1.8.0, < 2.0)
37
+ rubocop-ast (>= 1.15.1, < 2.0)
38
38
  ruby-progressbar (~> 1.7)
39
39
  unicode-display_width (>= 1.4.0, < 3.0)
40
- rubocop-ast (1.8.0)
41
- parser (>= 3.0.1.1)
42
- rubocop-rake (0.5.1)
43
- rubocop
44
- rubocop-rspec (2.0.1)
40
+ rubocop-ast (1.16.0)
41
+ parser (>= 3.1.1.0)
42
+ rubocop-rake (0.6.0)
45
43
  rubocop (~> 1.0)
46
- rubocop-ast (>= 1.1.0)
44
+ rubocop-rspec (2.9.0)
45
+ rubocop (~> 1.19)
47
46
  ruby-progressbar (1.11.0)
48
- unicode-display_width (2.0.0)
47
+ unicode-display_width (2.1.0)
49
48
 
50
49
  PLATFORMS
51
50
  ruby
52
51
 
53
52
  DEPENDENCIES
54
53
  rake (~> 12.0)
55
- rspec (~> 3.10)
56
- rubocop (~> 1.5)
57
- rubocop-ast (~> 1.3)
58
- rubocop-rake (~> 0.5.1)
59
- rubocop-rspec (~> 2.0.0)
54
+ rspec (~> 3.11.0)
55
+ rubocop (~> 1.25.1)
56
+ rubocop-ast (~> 1.16.0)
57
+ rubocop-rake (~> 0.6.0)
58
+ rubocop-rspec (~> 2.9.0)
60
59
  strum-service!
61
60
 
62
61
  BUNDLED WITH
63
- 2.2.15
62
+ 2.3.16
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Strum
4
4
  module Service
5
- VERSION = "0.2.0"
5
+ VERSION = "0.2.3"
6
6
  end
7
7
  end
data/lib/strum/service.rb CHANGED
@@ -45,8 +45,8 @@ module Strum
45
45
 
46
46
  def execute
47
47
  catch(:exit) do
48
- audit
49
48
  yield(self) if block_given?
49
+ audit
50
50
  call if valid?
51
51
  end
52
52
  valid? ? valid_result : invalid_result
@@ -77,14 +77,15 @@ module Strum
77
77
  end
78
78
 
79
79
  def method_missing(method_name, *args, &_block)
80
- (args.count.zero? &&
81
- (input.is_a?(Hash) && input[method_name.to_sym]) ||
82
- inputs[method_name.to_sym]) ||
83
- super
80
+ if args.count.zero? && (input.is_a?(Hash) && input.keys.include?(method_name.to_sym))
81
+ input[method_name.to_sym]
82
+ else
83
+ inputs[method_name.to_sym] || super
84
+ end
84
85
  end
85
86
 
86
87
  def respond_to_missing?(method_name, include_private = false)
87
- input.is_a?(Hash) && input[method_name.to_sym] || super
88
+ (input.is_a?(Hash) && input[method_name.to_sym]) || super
88
89
  end
89
90
 
90
91
  protected
@@ -169,7 +170,7 @@ module Strum
169
170
  end
170
171
 
171
172
  def sliced_list(*keys)
172
- add_error(:input, :must_be_array) && retuen unless input.is_a?(Array)
173
+ add_error(:input, :must_be_array) && return unless input.is_a?(Array)
173
174
 
174
175
  self.input = input.map do |item|
175
176
  if item.is_a?(Hash)
@@ -29,4 +29,5 @@ Gem::Specification.new do |spec|
29
29
  spec.bindir = "exe"
30
30
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
31
31
  spec.require_paths = ["lib"]
32
+ spec.metadata["rubygems_mfa_required"] = "false"
32
33
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: strum-service
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Serhiy Nazarov
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-08-05 00:00:00.000000000 Z
11
+ date: 2022-06-21 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Strum Service
14
14
  email:
@@ -42,6 +42,7 @@ metadata:
42
42
  source_code_uri: https://gitlab.com/strum-rb/strum-service
43
43
  changelog_uri: https://gitlab.com/strum-rb/strum-service/-/blob/master/CHANGELOG.md
44
44
  bug_tracker_uri: https://gitlab.com/strum-rb/strum-service/issues
45
+ rubygems_mfa_required: 'false'
45
46
  post_install_message:
46
47
  rdoc_options: []
47
48
  require_paths: