mutations-validate-outcome 0.8.2 → 0.9.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: 17fa9900ea6071170fb08b422168767a0742c7d7
4
- data.tar.gz: c79145c76c2d5a919c1e76b2b6f1c69beca719ac
3
+ metadata.gz: 1dea11e173fab845a367d0710543589351420ba4
4
+ data.tar.gz: cedce8f18857c45e40db78afe409cc32e13dfb1f
5
5
  SHA512:
6
- metadata.gz: afee3c02f19cf01fec6b346d834f1f83df57d65415d65b135f1afa410b54039386c4ef0933f34a3b3fe14589eadb9e0a48e8692371855959385d9c6756a7191a
7
- data.tar.gz: 61ffc28639a24e450f70618aa78d9363c14dba21130552b54e922352d6956080c8b2eb7784f920daf204cd0eefe87011c6176e5e11a468a2e5ceee93046c23fa
6
+ metadata.gz: 7e6d27d43c2e34cab545e0cf9f233120d77a1611344433cd6260be439b956b7e1a25af81b89233e9c680ee70e269086eae9506e90ef667325081e30bcff64c2d
7
+ data.tar.gz: a01c3c62d597337814b2a96cd79c8af086f3ca7889293e2344ddae0252f9b56dc48b66bfd5f7afe7ea40672482f1d6226a4a405be9743a39e45ade8eeb5356a4
data/.rubocop.yml CHANGED
@@ -32,3 +32,6 @@ Metrics/MethodLength:
32
32
 
33
33
  Metrics/PerceivedComplexity:
34
34
  Max: 42
35
+
36
+ Metrics/BlockLength:
37
+ Enabled: false
data/README.md CHANGED
@@ -89,6 +89,10 @@ class SimpleCommandReturningArray < Mutations::CommandReturningArray
89
89
  end
90
90
  ```
91
91
 
92
+ ## Changelog
93
+
94
+ #### `0.9.0` — `ActiveRecord::Relation` support
95
+
92
96
  ## License
93
97
 
94
98
  The gem is produced by [Kantox LTD](https://kantox.com).
@@ -50,7 +50,7 @@ module Mutations
50
50
  validation_outcome(
51
51
  execute.tap do |result|
52
52
  case result
53
- when Array
53
+ when Array, ActiveRecord::Relation
54
54
  result.each_with_index.with_object({}) do |(e, i), memo|
55
55
  _, outcome_error = self.class.outcome_filters.filter(e)
56
56
  outcome_error = validate_outcome(e) if outcome_error.nil?
@@ -1,5 +1,5 @@
1
1
  module Mutations
2
2
  module ValidateOutcome
3
- VERSION = '0.8.2'.freeze
3
+ VERSION = '0.9.0'.freeze
4
4
  end
5
5
  end
@@ -1,4 +1,3 @@
1
- # coding: utf-8
2
1
  lib = File.expand_path('../lib', __FILE__)
3
2
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
3
  require 'mutations/version'
@@ -32,7 +31,9 @@ Gem::Specification.new do |spec|
32
31
  spec.add_development_dependency 'minitest-color', '~> 0'
33
32
  spec.add_development_dependency 'minitest-documentation', '~> 0'
34
33
  spec.add_development_dependency 'pry', '~> 0.10'
34
+ spec.add_development_dependency 'sqlite3', '~> 1.3'
35
+ spec.add_development_dependency 'activerecord', '>= 3.2.21', '< 5.0.0'
35
36
 
36
- spec.add_dependency 'activesupport', '~> 3'
37
+ spec.add_dependency 'activesupport', '>= 3.2.21', '< 5.0.0'
37
38
  spec.add_dependency 'mutations', '~> 0.8'
38
39
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mutations-validate-outcome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.2
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aleksei Matiushkin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-09 00:00:00.000000000 Z
11
+ date: 2017-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -95,19 +95,59 @@ dependencies:
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0.10'
97
97
  - !ruby/object:Gem::Dependency
98
- name: activesupport
98
+ name: sqlite3
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '3'
104
- type: :runtime
103
+ version: '1.3'
104
+ type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: '3'
110
+ version: '1.3'
111
+ - !ruby/object:Gem::Dependency
112
+ name: activerecord
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: 3.2.21
118
+ - - "<"
119
+ - !ruby/object:Gem::Version
120
+ version: 5.0.0
121
+ type: :development
122
+ prerelease: false
123
+ version_requirements: !ruby/object:Gem::Requirement
124
+ requirements:
125
+ - - ">="
126
+ - !ruby/object:Gem::Version
127
+ version: 3.2.21
128
+ - - "<"
129
+ - !ruby/object:Gem::Version
130
+ version: 5.0.0
131
+ - !ruby/object:Gem::Dependency
132
+ name: activesupport
133
+ requirement: !ruby/object:Gem::Requirement
134
+ requirements:
135
+ - - ">="
136
+ - !ruby/object:Gem::Version
137
+ version: 3.2.21
138
+ - - "<"
139
+ - !ruby/object:Gem::Version
140
+ version: 5.0.0
141
+ type: :runtime
142
+ prerelease: false
143
+ version_requirements: !ruby/object:Gem::Requirement
144
+ requirements:
145
+ - - ">="
146
+ - !ruby/object:Gem::Version
147
+ version: 3.2.21
148
+ - - "<"
149
+ - !ruby/object:Gem::Version
150
+ version: 5.0.0
111
151
  - !ruby/object:Gem::Dependency
112
152
  name: mutations
113
153
  requirement: !ruby/object:Gem::Requirement