validators 0.1.3 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile.lock +30 -41
- data/lib/validators.rb +0 -1
- data/lib/validators/validates_datetime.rb +1 -1
- data/lib/validators/validates_email_format_of.rb +1 -1
- data/lib/validators/validates_ip_address.rb +1 -1
- data/lib/validators/validates_url_format_of.rb +1 -1
- data/lib/validators/version.rb +3 -3
- data/spec/spec_helper.rb +1 -0
- data/validators.gemspec +3 -3
- metadata +59 -60
data/Gemfile.lock
CHANGED
@@ -1,58 +1,47 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
validators (0.
|
5
|
-
activerecord (>= 3.0.0)
|
4
|
+
validators (1.0.0)
|
6
5
|
|
7
6
|
GEM
|
8
7
|
remote: http://rubygems.org/
|
9
8
|
specs:
|
10
|
-
activemodel (3.
|
11
|
-
activesupport (= 3.
|
12
|
-
builder (~>
|
13
|
-
i18n (~> 0.
|
14
|
-
activerecord (3.
|
15
|
-
activemodel (= 3.
|
16
|
-
activesupport (= 3.
|
17
|
-
arel (~> 2.
|
18
|
-
tzinfo (~> 0.3.
|
19
|
-
activesupport (3.
|
20
|
-
|
21
|
-
arel (2.
|
22
|
-
builder (
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
rspec-
|
30
|
-
rspec-
|
31
|
-
|
32
|
-
rspec-
|
33
|
-
rspec-expectations (2.5.0)
|
9
|
+
activemodel (3.1.3)
|
10
|
+
activesupport (= 3.1.3)
|
11
|
+
builder (~> 3.0.0)
|
12
|
+
i18n (~> 0.6)
|
13
|
+
activerecord (3.1.3)
|
14
|
+
activemodel (= 3.1.3)
|
15
|
+
activesupport (= 3.1.3)
|
16
|
+
arel (~> 2.2.1)
|
17
|
+
tzinfo (~> 0.3.29)
|
18
|
+
activesupport (3.1.3)
|
19
|
+
multi_json (~> 1.0)
|
20
|
+
arel (2.2.1)
|
21
|
+
builder (3.0.0)
|
22
|
+
diff-lcs (1.1.3)
|
23
|
+
i18n (0.6.0)
|
24
|
+
multi_json (1.0.4)
|
25
|
+
rake (0.9.2.2)
|
26
|
+
rspec (2.7.0)
|
27
|
+
rspec-core (~> 2.7.0)
|
28
|
+
rspec-expectations (~> 2.7.0)
|
29
|
+
rspec-mocks (~> 2.7.0)
|
30
|
+
rspec-core (2.7.1)
|
31
|
+
rspec-expectations (2.7.0)
|
34
32
|
diff-lcs (~> 1.1.2)
|
35
|
-
rspec-mocks (2.
|
36
|
-
|
37
|
-
columnize (>= 0.3.1)
|
38
|
-
linecache19 (>= 0.5.11)
|
39
|
-
ruby_core_source (>= 0.1.4)
|
40
|
-
ruby-debug19 (0.11.6)
|
41
|
-
columnize (>= 0.3.1)
|
42
|
-
linecache19 (>= 0.5.11)
|
43
|
-
ruby-debug-base19 (>= 0.11.19)
|
44
|
-
ruby_core_source (0.1.5)
|
45
|
-
archive-tar-minitar (>= 0.5.2)
|
46
|
-
sqlite3 (1.3.3)
|
33
|
+
rspec-mocks (2.7.0)
|
34
|
+
sqlite3 (1.3.5)
|
47
35
|
sqlite3-ruby (1.3.3)
|
48
36
|
sqlite3 (>= 1.3.3)
|
49
|
-
tzinfo (0.3.
|
37
|
+
tzinfo (0.3.31)
|
50
38
|
|
51
39
|
PLATFORMS
|
52
40
|
ruby
|
53
41
|
|
54
42
|
DEPENDENCIES
|
55
|
-
|
56
|
-
|
43
|
+
activerecord (~> 3.0)
|
44
|
+
rake
|
45
|
+
rspec (~> 2.7)
|
57
46
|
sqlite3-ruby
|
58
47
|
validators!
|
data/lib/validators.rb
CHANGED
@@ -68,7 +68,7 @@ module ActiveModel
|
|
68
68
|
end
|
69
69
|
|
70
70
|
module ClassMethods
|
71
|
-
# Validates
|
71
|
+
# Validates whether or not the specified e-mail address is valid.
|
72
72
|
#
|
73
73
|
# class User < ActiveRecord::Base
|
74
74
|
# validates_datetime :birth
|
@@ -12,7 +12,7 @@ module ActiveModel
|
|
12
12
|
end
|
13
13
|
|
14
14
|
module ClassMethods
|
15
|
-
# Validates
|
15
|
+
# Validates whether or not the specified e-mail address is valid.
|
16
16
|
#
|
17
17
|
# class User < ActiveRecord::Base
|
18
18
|
# validates_email_format_of :email
|
@@ -33,7 +33,7 @@ module ActiveModel
|
|
33
33
|
end
|
34
34
|
|
35
35
|
module ClassMethods
|
36
|
-
# Validates
|
36
|
+
# Validates whether or not the specified URL is valid.
|
37
37
|
#
|
38
38
|
# validates_ip_address :ip #=> accepts both v4 and v6
|
39
39
|
# validates_ip_address :ip, :only => :v4
|
data/lib/validators/version.rb
CHANGED
data/spec/spec_helper.rb
CHANGED
data/validators.gemspec
CHANGED
@@ -17,8 +17,8 @@ Gem::Specification.new do |s|
|
|
17
17
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
18
18
|
s.require_paths = ["lib"]
|
19
19
|
|
20
|
-
s.
|
21
|
-
s.add_development_dependency "rspec", "~> 2.
|
20
|
+
s.add_development_dependency "activerecord", "~> 3.0"
|
21
|
+
s.add_development_dependency "rspec", "~> 2.7"
|
22
22
|
s.add_development_dependency "sqlite3-ruby"
|
23
|
-
s.add_development_dependency "
|
23
|
+
s.add_development_dependency "rake"
|
24
24
|
end
|
metadata
CHANGED
@@ -1,71 +1,67 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: validators
|
3
|
-
version: !ruby/object:Gem::Version
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.0
|
4
5
|
prerelease:
|
5
|
-
version: 0.1.3
|
6
6
|
platform: ruby
|
7
|
-
authors:
|
7
|
+
authors:
|
8
8
|
- Nando Vieira
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-12-14 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
16
15
|
name: activerecord
|
17
|
-
|
18
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &70198104735240 !ruby/object:Gem::Requirement
|
19
17
|
none: false
|
20
|
-
requirements:
|
21
|
-
- -
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version: 3.0
|
24
|
-
type: :
|
25
|
-
version_requirements: *id001
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
|
-
name: rspec
|
18
|
+
requirements:
|
19
|
+
- - ~>
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '3.0'
|
22
|
+
type: :development
|
28
23
|
prerelease: false
|
29
|
-
|
24
|
+
version_requirements: *70198104735240
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: rspec
|
27
|
+
requirement: &70198104734720 !ruby/object:Gem::Requirement
|
30
28
|
none: false
|
31
|
-
requirements:
|
29
|
+
requirements:
|
32
30
|
- - ~>
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version: 2.
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '2.7'
|
35
33
|
type: :development
|
36
|
-
version_requirements: *id002
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: sqlite3-ruby
|
39
34
|
prerelease: false
|
40
|
-
|
35
|
+
version_requirements: *70198104734720
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: sqlite3-ruby
|
38
|
+
requirement: &70198104734340 !ruby/object:Gem::Requirement
|
41
39
|
none: false
|
42
|
-
requirements:
|
43
|
-
- -
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
version:
|
40
|
+
requirements:
|
41
|
+
- - ! '>='
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '0'
|
46
44
|
type: :development
|
47
|
-
version_requirements: *id003
|
48
|
-
- !ruby/object:Gem::Dependency
|
49
|
-
name: ruby-debug19
|
50
45
|
prerelease: false
|
51
|
-
|
46
|
+
version_requirements: *70198104734340
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: rake
|
49
|
+
requirement: &70198104733860 !ruby/object:Gem::Requirement
|
52
50
|
none: false
|
53
|
-
requirements:
|
54
|
-
- -
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
version:
|
51
|
+
requirements:
|
52
|
+
- - ! '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
57
55
|
type: :development
|
58
|
-
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: *70198104733860
|
59
58
|
description: Add some nice Rails 3 ActiveRecord validators.
|
60
|
-
email:
|
59
|
+
email:
|
61
60
|
- fnando.vieira@gmail.com
|
62
61
|
executables: []
|
63
|
-
|
64
62
|
extensions: []
|
65
|
-
|
66
63
|
extra_rdoc_files: []
|
67
|
-
|
68
|
-
files:
|
64
|
+
files:
|
69
65
|
- .gitignore
|
70
66
|
- .rspec
|
71
67
|
- Gemfile
|
@@ -98,32 +94,35 @@ files:
|
|
98
94
|
- validators.gemspec
|
99
95
|
homepage: http://rubygems.org/gems/validators
|
100
96
|
licenses: []
|
101
|
-
|
102
97
|
post_install_message:
|
103
98
|
rdoc_options: []
|
104
|
-
|
105
|
-
require_paths:
|
99
|
+
require_paths:
|
106
100
|
- lib
|
107
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
101
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
108
102
|
none: false
|
109
|
-
requirements:
|
110
|
-
- -
|
111
|
-
- !ruby/object:Gem::Version
|
112
|
-
version:
|
113
|
-
|
103
|
+
requirements:
|
104
|
+
- - ! '>='
|
105
|
+
- !ruby/object:Gem::Version
|
106
|
+
version: '0'
|
107
|
+
segments:
|
108
|
+
- 0
|
109
|
+
hash: -3805126046563644054
|
110
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
114
111
|
none: false
|
115
|
-
requirements:
|
116
|
-
- -
|
117
|
-
- !ruby/object:Gem::Version
|
118
|
-
version:
|
112
|
+
requirements:
|
113
|
+
- - ! '>='
|
114
|
+
- !ruby/object:Gem::Version
|
115
|
+
version: '0'
|
116
|
+
segments:
|
117
|
+
- 0
|
118
|
+
hash: -3805126046563644054
|
119
119
|
requirements: []
|
120
|
-
|
121
120
|
rubyforge_project:
|
122
|
-
rubygems_version: 1.
|
121
|
+
rubygems_version: 1.8.11
|
123
122
|
signing_key:
|
124
123
|
specification_version: 3
|
125
124
|
summary: Add some nice Rails 3 ActiveRecord validators.
|
126
|
-
test_files:
|
125
|
+
test_files:
|
127
126
|
- spec/schema.rb
|
128
127
|
- spec/spec_helper.rb
|
129
128
|
- spec/support/dates.rb
|