moneta-api 1.4.0 → 1.5.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
  SHA1:
3
- metadata.gz: 65fd81e67ce614a1bc31b895f2c105ec68a30807
4
- data.tar.gz: 69d02d7b6abb626d2588902a95743dcbf7b4d088
3
+ metadata.gz: b94ff62b0bfb5314efaca9fbd33af31eea4cafd9
4
+ data.tar.gz: 667399b9dadad29b3b0e6e631e516f65b91d29c5
5
5
  SHA512:
6
- metadata.gz: 6be281b398a3fd97c3c100c432a166cd83a775d32f7b49a1ab524d750ab6985568ea8579877fb42df6c83a7dd5a40d4057fe7f642a185cf521328009f75c0a2e
7
- data.tar.gz: 690248a5900235efc708dfe590a2f5b0c46dae3011b4f1725254e688c9121f33e03e5546e8955dd18447f3fcbc7e363025b2127ccf1a799606e84c79307b58b5
6
+ metadata.gz: c2e1a984ac28323d1df1e088c36abfcb791a2719e3647df743b6f01816f389ff59c821b70e0d7201c14e331f3c5ccd85dce2d72ed0e521a73200dad30b40f144
7
+ data.tar.gz: b226705780342dc194d69f09d422496daf95f210a4f27c8af3d4e9c7b032458199697466de5029b471e8f4274af4d710c125e5b22506b35af15f75812b490ab4
@@ -82,6 +82,10 @@ module Moneta
82
82
  raise TypeError.new("TypeError: can't convert #{ item.class } into Moneta::Api::Types::KeyValueAttribute")
83
83
  end
84
84
  end
85
+
86
+ def get_attribute(attribute_name)
87
+ Array(@attribute).detect { |attribute| attribute.key.to_s == attribute_name.to_s }
88
+ end
85
89
  end
86
90
  end
87
91
  end
@@ -1,5 +1,5 @@
1
1
  module Moneta
2
2
  module Api
3
- VERSION = '1.4.0'
3
+ VERSION = '1.5.0'
4
4
  end
5
5
  end
@@ -20,4 +20,14 @@ describe Moneta::Api::Types::OperationInfo do
20
20
  it { expect{ subject }.to raise_error(TypeError) }
21
21
  end
22
22
  end
23
+
24
+ describe '#get_attribute' do
25
+ before do
26
+ operation_info.add_attribute(Moneta::Api::Types::KeyValueAttribute.new.fill(key: 'key', value: 'value'))
27
+ end
28
+
29
+ subject { operation_info.get_attribute('key') }
30
+
31
+ it { is_expected.to be_a Moneta::Api::Types::KeyValueAttribute }
32
+ end
23
33
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: moneta-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ssnikolay
@@ -9,149 +9,149 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-11-17 00:00:00.000000000 Z
12
+ date: 2016-01-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: savon
16
16
  requirement: !ruby/object:Gem::Requirement
17
17
  requirements:
18
- - - ~>
18
+ - - "~>"
19
19
  - !ruby/object:Gem::Version
20
20
  version: 2.10.0
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
- - - ~>
25
+ - - "~>"
26
26
  - !ruby/object:Gem::Version
27
27
  version: 2.10.0
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: bundler
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
- - - ~>
32
+ - - "~>"
33
33
  - !ruby/object:Gem::Version
34
34
  version: '1.7'
35
35
  type: :development
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
- - - ~>
39
+ - - "~>"
40
40
  - !ruby/object:Gem::Version
41
41
  version: '1.7'
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: rake
44
44
  requirement: !ruby/object:Gem::Requirement
45
45
  requirements:
46
- - - ~>
46
+ - - "~>"
47
47
  - !ruby/object:Gem::Version
48
48
  version: '10.0'
49
49
  type: :development
50
50
  prerelease: false
51
51
  version_requirements: !ruby/object:Gem::Requirement
52
52
  requirements:
53
- - - ~>
53
+ - - "~>"
54
54
  - !ruby/object:Gem::Version
55
55
  version: '10.0'
56
56
  - !ruby/object:Gem::Dependency
57
57
  name: pry
58
58
  requirement: !ruby/object:Gem::Requirement
59
59
  requirements:
60
- - - '>='
60
+ - - ">="
61
61
  - !ruby/object:Gem::Version
62
62
  version: '0'
63
63
  type: :development
64
64
  prerelease: false
65
65
  version_requirements: !ruby/object:Gem::Requirement
66
66
  requirements:
67
- - - '>='
67
+ - - ">="
68
68
  - !ruby/object:Gem::Version
69
69
  version: '0'
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: rspec
72
72
  requirement: !ruby/object:Gem::Requirement
73
73
  requirements:
74
- - - '>='
74
+ - - ">="
75
75
  - !ruby/object:Gem::Version
76
76
  version: '0'
77
77
  type: :development
78
78
  prerelease: false
79
79
  version_requirements: !ruby/object:Gem::Requirement
80
80
  requirements:
81
- - - '>='
81
+ - - ">="
82
82
  - !ruby/object:Gem::Version
83
83
  version: '0'
84
84
  - !ruby/object:Gem::Dependency
85
85
  name: rspec-its
86
86
  requirement: !ruby/object:Gem::Requirement
87
87
  requirements:
88
- - - '>='
88
+ - - ">="
89
89
  - !ruby/object:Gem::Version
90
90
  version: '0'
91
91
  type: :development
92
92
  prerelease: false
93
93
  version_requirements: !ruby/object:Gem::Requirement
94
94
  requirements:
95
- - - '>='
95
+ - - ">="
96
96
  - !ruby/object:Gem::Version
97
97
  version: '0'
98
98
  - !ruby/object:Gem::Dependency
99
99
  name: vcr
100
100
  requirement: !ruby/object:Gem::Requirement
101
101
  requirements:
102
- - - '>='
102
+ - - ">="
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
105
  type: :development
106
106
  prerelease: false
107
107
  version_requirements: !ruby/object:Gem::Requirement
108
108
  requirements:
109
- - - '>='
109
+ - - ">="
110
110
  - !ruby/object:Gem::Version
111
111
  version: '0'
112
112
  - !ruby/object:Gem::Dependency
113
113
  name: fakeweb
114
114
  requirement: !ruby/object:Gem::Requirement
115
115
  requirements:
116
- - - '>='
116
+ - - ">="
117
117
  - !ruby/object:Gem::Version
118
118
  version: '0'
119
119
  type: :development
120
120
  prerelease: false
121
121
  version_requirements: !ruby/object:Gem::Requirement
122
122
  requirements:
123
- - - '>='
123
+ - - ">="
124
124
  - !ruby/object:Gem::Version
125
125
  version: '0'
126
126
  - !ruby/object:Gem::Dependency
127
127
  name: yard
128
128
  requirement: !ruby/object:Gem::Requirement
129
129
  requirements:
130
- - - '>='
130
+ - - ">="
131
131
  - !ruby/object:Gem::Version
132
132
  version: '0'
133
133
  type: :development
134
134
  prerelease: false
135
135
  version_requirements: !ruby/object:Gem::Requirement
136
136
  requirements:
137
- - - '>='
137
+ - - ">="
138
138
  - !ruby/object:Gem::Version
139
139
  version: '0'
140
140
  - !ruby/object:Gem::Dependency
141
141
  name: codeclimate-test-reporter
142
142
  requirement: !ruby/object:Gem::Requirement
143
143
  requirements:
144
- - - '>='
144
+ - - ">="
145
145
  - !ruby/object:Gem::Version
146
146
  version: '0'
147
147
  type: :development
148
148
  prerelease: false
149
149
  version_requirements: !ruby/object:Gem::Requirement
150
150
  requirements:
151
- - - '>='
151
+ - - ">="
152
152
  - !ruby/object:Gem::Version
153
153
  version: '0'
154
- description: МОНЕТА.РУ (MONETA.MerchantAPI.v2).
154
+ description: "МОНЕТА.РУ (MONETA.MerchantAPI.v2)."
155
155
  email:
156
156
  - ssnikolay@gmail.com
157
157
  - ll.wg.bin@gmail.com
@@ -159,10 +159,10 @@ executables: []
159
159
  extensions: []
160
160
  extra_rdoc_files: []
161
161
  files:
162
- - .gitignore
163
- - .rspec
164
- - .travis.yml
165
- - .yardopts
162
+ - ".gitignore"
163
+ - ".rspec"
164
+ - ".travis.yml"
165
+ - ".yardopts"
166
166
  - Gemfile
167
167
  - LICENSE.txt
168
168
  - README.md
@@ -339,20 +339,20 @@ require_paths:
339
339
  - lib
340
340
  required_ruby_version: !ruby/object:Gem::Requirement
341
341
  requirements:
342
- - - '>='
342
+ - - ">="
343
343
  - !ruby/object:Gem::Version
344
344
  version: '0'
345
345
  required_rubygems_version: !ruby/object:Gem::Requirement
346
346
  requirements:
347
- - - '>='
347
+ - - ">="
348
348
  - !ruby/object:Gem::Version
349
349
  version: '0'
350
350
  requirements: []
351
351
  rubyforge_project:
352
- rubygems_version: 2.4.3
352
+ rubygems_version: 2.4.8
353
353
  signing_key:
354
354
  specification_version: 4
355
- summary: МОНЕТА.РУ (MONETA.MerchantAPI.v2)
355
+ summary: "МОНЕТА.РУ (MONETA.MerchantAPI.v2)"
356
356
  test_files:
357
357
  - spec/lib/moneta/api/requests/authorise_transaction_batch_request_spec.rb
358
358
  - spec/lib/moneta/api/requests/authorise_transaction_request_spec.rb