enumerate_it 1.2.8 → 1.2.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +3 -24
- data/{spec/spec.opts → .rspec} +0 -0
- data/.travis.yml +17 -0
- data/Appraisals +6 -0
- data/CHANGELOG.md +1 -0
- data/Gemfile.lock +33 -30
- data/{README.markdown → README.md} +96 -104
- data/Rakefile +1 -1
- data/enumerate_it.gemspec +22 -0
- data/gemfiles/activesupport_3_0.gemfile +8 -0
- data/gemfiles/activesupport_3_1.gemfile +8 -0
- data/gemfiles/activesupport_3_2.gemfile +8 -0
- data/gemfiles/activesupport_4_0.gemfile +8 -0
- data/gemfiles/activesupport_4_1.gemfile +8 -0
- data/gemfiles/activesupport_4_2.gemfile +8 -0
- data/lib/enumerate_it.rb +4 -266
- data/lib/enumerate_it/base.rb +3 -2
- data/lib/enumerate_it/version.rb +1 -1
- data/spec/enumerate_it/base_spec.rb +35 -5
- data/spec/enumerate_it_spec.rb +4 -1
- data/spec/spec_helper.rb +12 -12
- data/spec/support/test_classes.rb +1 -1
- metadata +26 -33
data/spec/enumerate_it_spec.rb
CHANGED
@@ -240,6 +240,10 @@ describe EnumerateIt do
|
|
240
240
|
|
241
241
|
context "if the hosting class responds to :scope" do
|
242
242
|
before do
|
243
|
+
if ActiveSupport::VERSION::STRING =~ /3\.1/
|
244
|
+
Object.send :remove_const, 'OtherTestClass' if defined?(OtherTestClass)
|
245
|
+
end
|
246
|
+
|
243
247
|
class OtherTestClass < ActiveRecord::Base
|
244
248
|
extend EnumerateIt
|
245
249
|
end
|
@@ -291,4 +295,3 @@ describe EnumerateIt do
|
|
291
295
|
end
|
292
296
|
end
|
293
297
|
end
|
294
|
-
|
data/spec/spec_helper.rb
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
-
$LOAD_PATH.unshift
|
2
|
-
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "..", "lib"))
|
3
|
-
require "enumerate_it"
|
4
|
-
require "rspec"
|
5
|
-
require "rspec/autorun"
|
1
|
+
$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__)
|
6
2
|
|
7
|
-
require
|
8
|
-
require "active_support"
|
9
|
-
require "active_record"
|
10
|
-
require "active_support/core_ext/string/inflections"
|
11
|
-
require "active_support/core_ext/object/to_json"
|
3
|
+
require 'enumerate_it'
|
12
4
|
|
13
|
-
|
5
|
+
require 'active_support/all'
|
6
|
+
require 'active_record'
|
14
7
|
|
15
|
-
|
8
|
+
Dir['./spec/support/**/*.rb'].each { |f| require f }
|
9
|
+
|
10
|
+
I18n.config.enforce_available_locales = false
|
11
|
+
I18n.load_path = Dir['spec/i18n/*.yml']
|
12
|
+
|
13
|
+
# RSpec.configure do |config|
|
14
|
+
# config.filter_run_including focus: true
|
15
|
+
# end
|
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: enumerate_it
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cássio Marques
|
8
|
+
- Lucas Caton
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date:
|
12
|
+
date: 2016-03-27 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: activesupport
|
@@ -25,7 +26,7 @@ dependencies:
|
|
25
26
|
- !ruby/object:Gem::Version
|
26
27
|
version: 3.0.0
|
27
28
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
29
|
+
name: appraisal
|
29
30
|
requirement: !ruby/object:Gem::Requirement
|
30
31
|
requirements:
|
31
32
|
- - ">="
|
@@ -39,35 +40,21 @@ dependencies:
|
|
39
40
|
- !ruby/object:Gem::Version
|
40
41
|
version: '0'
|
41
42
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: 2.5.0
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: 2.5.0
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: activerecord
|
43
|
+
name: pry
|
57
44
|
requirement: !ruby/object:Gem::Requirement
|
58
45
|
requirements:
|
59
46
|
- - ">="
|
60
47
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
48
|
+
version: '0'
|
62
49
|
type: :development
|
63
50
|
prerelease: false
|
64
51
|
version_requirements: !ruby/object:Gem::Requirement
|
65
52
|
requirements:
|
66
53
|
- - ">="
|
67
54
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
55
|
+
version: '0'
|
69
56
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
57
|
+
name: rake
|
71
58
|
requirement: !ruby/object:Gem::Requirement
|
72
59
|
requirements:
|
73
60
|
- - ">="
|
@@ -81,35 +68,43 @@ dependencies:
|
|
81
68
|
- !ruby/object:Gem::Version
|
82
69
|
version: '0'
|
83
70
|
- !ruby/object:Gem::Dependency
|
84
|
-
name:
|
71
|
+
name: rspec
|
85
72
|
requirement: !ruby/object:Gem::Requirement
|
86
73
|
requirements:
|
87
|
-
- - "
|
74
|
+
- - "~>"
|
88
75
|
- !ruby/object:Gem::Version
|
89
|
-
version:
|
76
|
+
version: 2.14.1
|
90
77
|
type: :development
|
91
78
|
prerelease: false
|
92
79
|
version_requirements: !ruby/object:Gem::Requirement
|
93
80
|
requirements:
|
94
|
-
- - "
|
81
|
+
- - "~>"
|
95
82
|
- !ruby/object:Gem::Version
|
96
|
-
version:
|
83
|
+
version: 2.14.1
|
97
84
|
description: Enumerations for Ruby with some magic powers!
|
98
|
-
email:
|
99
|
-
- cassiommc@gmail.com
|
85
|
+
email:
|
100
86
|
executables: []
|
101
87
|
extensions: []
|
102
88
|
extra_rdoc_files: []
|
103
89
|
files:
|
104
90
|
- ".document"
|
105
91
|
- ".gitignore"
|
92
|
+
- ".rspec"
|
106
93
|
- ".travis.yml"
|
94
|
+
- Appraisals
|
95
|
+
- CHANGELOG.md
|
107
96
|
- Gemfile
|
108
97
|
- Gemfile.lock
|
109
98
|
- LICENSE
|
110
|
-
- README.
|
99
|
+
- README.md
|
111
100
|
- Rakefile
|
112
101
|
- enumerate_it.gemspec
|
102
|
+
- gemfiles/activesupport_3_0.gemfile
|
103
|
+
- gemfiles/activesupport_3_1.gemfile
|
104
|
+
- gemfiles/activesupport_3_2.gemfile
|
105
|
+
- gemfiles/activesupport_4_0.gemfile
|
106
|
+
- gemfiles/activesupport_4_1.gemfile
|
107
|
+
- gemfiles/activesupport_4_2.gemfile
|
113
108
|
- lib/enumerate_it.rb
|
114
109
|
- lib/enumerate_it/base.rb
|
115
110
|
- lib/enumerate_it/class_methods.rb
|
@@ -125,10 +120,9 @@ files:
|
|
125
120
|
- spec/enumerate_it_spec.rb
|
126
121
|
- spec/i18n/en.yml
|
127
122
|
- spec/i18n/pt.yml
|
128
|
-
- spec/spec.opts
|
129
123
|
- spec/spec_helper.rb
|
130
124
|
- spec/support/test_classes.rb
|
131
|
-
homepage:
|
125
|
+
homepage: https://github.com/lucascaton/enumerate_it
|
132
126
|
licenses: []
|
133
127
|
metadata: {}
|
134
128
|
post_install_message:
|
@@ -147,7 +141,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
147
141
|
version: '0'
|
148
142
|
requirements: []
|
149
143
|
rubyforge_project:
|
150
|
-
rubygems_version: 2.
|
144
|
+
rubygems_version: 2.5.1
|
151
145
|
signing_key:
|
152
146
|
specification_version: 4
|
153
147
|
summary: Ruby Enumerations
|
@@ -156,6 +150,5 @@ test_files:
|
|
156
150
|
- spec/enumerate_it_spec.rb
|
157
151
|
- spec/i18n/en.yml
|
158
152
|
- spec/i18n/pt.yml
|
159
|
-
- spec/spec.opts
|
160
153
|
- spec/spec_helper.rb
|
161
154
|
- spec/support/test_classes.rb
|