validates_as_email_address 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +4 -0
- data/README +11 -10
- data/Rakefile +6 -6
- data/lib/validates_as_email_address.rb +71 -90
- data/lib/validates_as_email_address/rfc_822.rb +18 -0
- data/test/app_root/app/models/user.rb +3 -0
- data/test/app_root/db/migrate/001_create_users.rb +11 -0
- data/test/app_root/log/in_memory.log +39 -0
- data/test/test_helper.rb +5 -4
- data/test/{validates_as_email_address_test.rb → unit/validates_as_email_address_test.rb} +8 -14
- metadata +55 -36
data/CHANGELOG
CHANGED
data/README
CHANGED
@@ -5,25 +5,21 @@ email addresses.
|
|
5
5
|
|
6
6
|
== Resources
|
7
7
|
|
8
|
-
API
|
9
|
-
|
10
|
-
* http://api.pluginaweek.org/validates_as_email_address
|
11
|
-
|
12
8
|
Wiki
|
13
9
|
|
14
10
|
* http://wiki.pluginaweek.org/Validates_as_email_address
|
15
11
|
|
16
|
-
|
12
|
+
API
|
17
13
|
|
18
|
-
* http://
|
14
|
+
* http://api.pluginaweek.org/validates_as_email_address
|
19
15
|
|
20
|
-
|
16
|
+
Development
|
21
17
|
|
22
|
-
* http://
|
18
|
+
* http://dev.pluginaweek.org/browser/trunk/validates_as_email_address
|
23
19
|
|
24
|
-
|
20
|
+
Source
|
25
21
|
|
26
|
-
* http://
|
22
|
+
* http://svn.pluginaweek.org/trunk/validates_as_email_address
|
27
23
|
|
28
24
|
== Description
|
29
25
|
|
@@ -41,6 +37,11 @@ the email address.
|
|
41
37
|
validates_as_email_address :email, :on => :create
|
42
38
|
end
|
43
39
|
|
40
|
+
== Testing
|
41
|
+
|
42
|
+
Before you can run any tests, the following gem must be installed:
|
43
|
+
* plugin_test_helper[http://wiki.pluginaweek.org/Plugin_test_helper]
|
44
|
+
|
44
45
|
== References
|
45
46
|
|
46
47
|
* Cal Henderson - {Parsing Email Adresses in PHP}[http://iamcal.com/publish/articles/php/parsing_email]
|
data/Rakefile
CHANGED
@@ -4,7 +4,7 @@ require 'rake/gempackagetask'
|
|
4
4
|
require 'rake/contrib/sshpublisher'
|
5
5
|
|
6
6
|
PKG_NAME = 'validates_as_email_address'
|
7
|
-
PKG_VERSION = '0.0.
|
7
|
+
PKG_VERSION = '0.0.2'
|
8
8
|
PKG_FILE_NAME = "#{PKG_NAME}-#{PKG_VERSION}"
|
9
9
|
RUBY_FORGE_PROJECT = 'pluginaweek'
|
10
10
|
|
@@ -39,8 +39,8 @@ spec = Gem::Specification.new do |s|
|
|
39
39
|
s.has_rdoc = true
|
40
40
|
s.test_files = Dir['test/**/*_test.rb']
|
41
41
|
|
42
|
-
s.author = 'Aaron Pfeifer
|
43
|
-
s.email = '
|
42
|
+
s.author = 'Aaron Pfeifer'
|
43
|
+
s.email = 'aaron@pluginaweek.org'
|
44
44
|
s.homepage = 'http://www.pluginaweek.org'
|
45
45
|
end
|
46
46
|
|
@@ -52,12 +52,12 @@ end
|
|
52
52
|
|
53
53
|
desc 'Publish the beta gem'
|
54
54
|
task :pgem => [:package] do
|
55
|
-
Rake::SshFilePublisher.new('
|
55
|
+
Rake::SshFilePublisher.new('aaron@pluginaweek.org', '/home/aaron/gems.pluginaweek.org/public/gems', 'pkg', "#{PKG_FILE_NAME}.gem").upload
|
56
56
|
end
|
57
57
|
|
58
58
|
desc 'Publish the API documentation'
|
59
59
|
task :pdoc => [:rdoc] do
|
60
|
-
Rake::SshDirPublisher.new('
|
60
|
+
Rake::SshDirPublisher.new('aaron@pluginaweek.org', "/home/aaron/api.pluginaweek.org/public/#{PKG_NAME}", 'rdoc').upload
|
61
61
|
end
|
62
62
|
|
63
63
|
desc 'Publish the API docs and gem'
|
@@ -69,7 +69,7 @@ task :release => [:gem, :package] do
|
|
69
69
|
|
70
70
|
ruby_forge = RubyForge.new
|
71
71
|
ruby_forge.login
|
72
|
-
|
72
|
+
|
73
73
|
%w( gem tgz zip ).each do |ext|
|
74
74
|
file = "pkg/#{PKG_FILE_NAME}.#{ext}"
|
75
75
|
puts "Releasing #{File.basename(file)}..."
|
@@ -1,102 +1,83 @@
|
|
1
|
-
|
2
|
-
module RFC822
|
3
|
-
EmailAddress = begin
|
4
|
-
qtext = '[^\\x0d\\x22\\x5c\\x80-\\xff]'
|
5
|
-
dtext = '[^\\x0d\\x5b-\\x5d\\x80-\\xff]'
|
6
|
-
atom = '[^\\x00-\\x20\\x22\\x28\\x29\\x2c\\x2e\\x3a-\\x3c\\x3e\\x40\\x5b-\\x5d\\x7f-\\xff]+'
|
7
|
-
quoted_pair = '\\x5c[\\x00-\\x7f]'
|
8
|
-
domain_literal = "\\x5b(?:#{dtext}|#{quoted_pair})*\\x5d"
|
9
|
-
quoted_string = "\\x22(?:#{qtext}|#{quoted_pair})*\\x22"
|
10
|
-
domain_ref = atom
|
11
|
-
sub_domain = "(?:#{domain_ref}|#{domain_literal})"
|
12
|
-
word = "(?:#{atom}|#{quoted_string})"
|
13
|
-
domain = "#{sub_domain}(?:\\x2e#{sub_domain})*"
|
14
|
-
local_part = "#{word}(?:\\x2e#{word})*"
|
15
|
-
addr_spec = "(#{local_part})\\x40(#{domain})"
|
16
|
-
pattern = /\A#{addr_spec}\z/
|
17
|
-
end
|
18
|
-
end
|
1
|
+
require 'validates_as_email_address/rfc_822'
|
19
2
|
|
20
3
|
module PluginAWeek #:nodoc:
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
4
|
+
# Adds validations for email addresses
|
5
|
+
module ValidatesAsEmailAddress
|
6
|
+
# The options that can be used when validating the format of the email address
|
7
|
+
EMAIL_FORMAT_OPTIONS = [
|
8
|
+
:wrong_format,
|
9
|
+
:allow_nil,
|
10
|
+
:on,
|
11
|
+
:if
|
12
|
+
]
|
13
|
+
|
14
|
+
# The options that can be used when validating the length of the email address
|
15
|
+
EMAIL_LENGTH_OPTIONS = [
|
16
|
+
:minimum,
|
17
|
+
:maximum,
|
18
|
+
:is,
|
19
|
+
:within,
|
20
|
+
:in,
|
21
|
+
:too_long,
|
22
|
+
:too_short,
|
23
|
+
:wrong_length,
|
24
|
+
:allow_nil,
|
25
|
+
:on,
|
26
|
+
:if
|
27
|
+
]
|
28
|
+
|
29
|
+
# Validates whether the value of the specific attribute matches against the
|
30
|
+
# RFC822 specificiation.
|
31
|
+
#
|
32
|
+
# class Person < ActiveRecord::Base
|
33
|
+
# validates_as_email_address :email, :on => :create
|
34
|
+
# end
|
35
|
+
#
|
36
|
+
# This will also validate that the email address is within the specification
|
37
|
+
# limits, specifically between 3 and 320 characters in length.
|
38
|
+
#
|
39
|
+
# Configuration options for length:
|
40
|
+
# * +minimum+ - The minimum size of the attribute
|
41
|
+
# * +maximum+ - The maximum size of the attribute
|
42
|
+
# * +is+ - The exact size of the attribute
|
43
|
+
# * +within+ - A range specifying the minimum and maximum size of the attribute
|
44
|
+
# * +in+ - A synonym(or alias) for :within
|
45
|
+
# * +too_long+ - The error message if the attribute goes over the maximum (default is: "is too long (maximum is %d characters)")
|
46
|
+
# * +too_short+ - The error message if the attribute goes under the minimum (default is: "is too short (minimum is %d characters)")
|
47
|
+
# * +wrong_length+ - The error message if using the :is method and the attribute is the wrong size (default is: "is the wrong length (should be %d characters)")
|
48
|
+
#
|
49
|
+
# Configuration options for format:
|
50
|
+
# * +wrong_format+ - A custom error message (default is: "is an invalid email address")
|
51
|
+
#
|
52
|
+
# Configuration options for both length and format:
|
53
|
+
# * +allow_nil+ - Attribute may be nil; skip validation.
|
54
|
+
# * +on+ - Specifies when this validation is active (default is :save, other options :create, :update)
|
55
|
+
# * +if+ - Specifies a method, proc or string to call to determine if the validation should
|
56
|
+
# occur (e.g. :if => :allow_validation, or :if => Proc.new { |user| user.signup_step > 2 }). The
|
57
|
+
# method, proc or string should return or evaluate to a true or false value.
|
58
|
+
def validates_as_email_address(*attr_names)
|
59
|
+
configuration = attr_names.last.is_a?(Hash) ? attr_names.pop : {}
|
60
|
+
configuration.assert_valid_keys(EMAIL_FORMAT_OPTIONS | EMAIL_LENGTH_OPTIONS)
|
61
|
+
configuration.reverse_merge!(
|
62
|
+
:wrong_format => ActiveRecord::Errors.default_error_messages[:invalid_email]
|
63
|
+
)
|
31
64
|
|
32
|
-
#
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
:within,
|
38
|
-
:in,
|
39
|
-
:too_long,
|
40
|
-
:too_short,
|
41
|
-
:wrong_length,
|
42
|
-
:allow_nil,
|
43
|
-
:on,
|
44
|
-
:if
|
45
|
-
]
|
65
|
+
# Add format validation
|
66
|
+
format_configuration = configuration.reject {|key, value| !EMAIL_FORMAT_OPTIONS.include?(key)}
|
67
|
+
format_configuration[:message] = format_configuration.delete(:wrong_format)
|
68
|
+
format_configuration[:with] = RFC822::EmailAddress
|
69
|
+
validates_format_of attr_names, format_configuration
|
46
70
|
|
47
|
-
#
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
# validates_as_email_address :email, :on => :create
|
52
|
-
# end
|
53
|
-
#
|
54
|
-
# This will also validate that the email address is within the specification
|
55
|
-
# limits, specifically between 3 and 320 characters in length.
|
56
|
-
#
|
57
|
-
# Configuration options for length:
|
58
|
-
# * +minimum+ - The minimum size of the attribute
|
59
|
-
# * +maximum+ - The maximum size of the attribute
|
60
|
-
# * +is+ - The exact size of the attribute
|
61
|
-
# * +within+ - A range specifying the minimum and maximum size of the attribute
|
62
|
-
# * +in+ - A synonym(or alias) for :within
|
63
|
-
# * +too_long+ - The error message if the attribute goes over the maximum (default is: "is too long (maximum is %d characters)")
|
64
|
-
# * +too_short+ - The error message if the attribute goes under the minimum (default is: "is too short (minimum is %d characters)")
|
65
|
-
# * +wrong_length+ - The error message if using the :is method and the attribute is the wrong size (default is: "is the wrong length (should be %d characters)")
|
66
|
-
#
|
67
|
-
# Configuration options for format:
|
68
|
-
# * +wrong_format+ - A custom error message (default is: "is an invalid email address")
|
69
|
-
#
|
70
|
-
# Configuration options for both length and format:
|
71
|
-
# * +allow_nil+ - Attribute may be nil; skip validation.
|
72
|
-
# * +on+ - Specifies when this validation is active (default is :save, other options :create, :update)
|
73
|
-
# * +if+ - Specifies a method, proc or string to call to determine if the validation should
|
74
|
-
# occur (e.g. :if => :allow_validation, or :if => Proc.new { |user| user.signup_step > 2 }). The
|
75
|
-
# method, proc or string should return or evaluate to a true or false value.
|
76
|
-
def validates_as_email_address(*attr_names)
|
77
|
-
configuration = attr_names.last.is_a?(Hash) ? attr_names.pop : {}
|
78
|
-
configuration.assert_valid_keys(EMAIL_FORMAT_OPTIONS | EMAIL_LENGTH_OPTIONS)
|
79
|
-
configuration.reverse_merge!(
|
80
|
-
:wrong_format => ActiveRecord::Errors.default_error_messages[:invalid_email]
|
81
|
-
)
|
82
|
-
|
83
|
-
# Add format validation
|
84
|
-
format_configuration = configuration.reject {|key, value| !EMAIL_FORMAT_OPTIONS.include?(key)}
|
85
|
-
format_configuration[:message] = format_configuration.delete(:wrong_format)
|
86
|
-
format_configuration[:with] = RFC822::EmailAddress
|
87
|
-
validates_format_of attr_names, format_configuration
|
88
|
-
|
89
|
-
# Add length validation
|
90
|
-
length_configuration = configuration.reject {|key, value| !EMAIL_LENGTH_OPTIONS.include?(key)}
|
91
|
-
length_configuration.reverse_merge!(:within => 3..320)
|
92
|
-
validates_length_of attr_names, length_configuration
|
93
|
-
end
|
71
|
+
# Add length validation
|
72
|
+
length_configuration = configuration.reject {|key, value| !EMAIL_LENGTH_OPTIONS.include?(key)}
|
73
|
+
length_configuration.reverse_merge!(:within => 3..320)
|
74
|
+
validates_length_of attr_names, length_configuration
|
94
75
|
end
|
95
76
|
end
|
96
77
|
end
|
97
78
|
|
98
79
|
ActiveRecord::Base.class_eval do
|
99
|
-
extend PluginAWeek::
|
80
|
+
extend PluginAWeek::ValidatesAsEmailAddress
|
100
81
|
end
|
101
82
|
|
102
83
|
ActiveRecord::Errors.default_error_messages.update(
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# The standard describing the format of email addresses
|
2
|
+
module RFC822
|
3
|
+
EmailAddress = begin
|
4
|
+
qtext = '[^\\x0d\\x22\\x5c\\x80-\\xff]'
|
5
|
+
dtext = '[^\\x0d\\x5b-\\x5d\\x80-\\xff]'
|
6
|
+
atom = '[^\\x00-\\x20\\x22\\x28\\x29\\x2c\\x2e\\x3a-\\x3c\\x3e\\x40\\x5b-\\x5d\\x7f-\\xff]+'
|
7
|
+
quoted_pair = '\\x5c[\\x00-\\x7f]'
|
8
|
+
domain_literal = "\\x5b(?:#{dtext}|#{quoted_pair})*\\x5d"
|
9
|
+
quoted_string = "\\x22(?:#{qtext}|#{quoted_pair})*\\x22"
|
10
|
+
domain_ref = atom
|
11
|
+
sub_domain = "(?:#{domain_ref}|#{domain_literal})"
|
12
|
+
word = "(?:#{atom}|#{quoted_string})"
|
13
|
+
domain = "#{sub_domain}(?:\\x2e#{sub_domain})*"
|
14
|
+
local_part = "#{word}(?:\\x2e#{word})*"
|
15
|
+
addr_spec = "(#{local_part})\\x40(#{domain})"
|
16
|
+
pattern = /\A#{addr_spec}\z/
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
# Logfile created on Sun Apr 06 00:59:11 -0400 2008 [4;36;1mSQL (0.000430)[0m [0;1mselect sqlite_version(*)[0m
|
2
|
+
[4;35;1mSQL (0.000442)[0m [0mCREATE TABLE "schema_info" (version varchar(255))[0m
|
3
|
+
[4;36;1mSQL (0.000121)[0m [0;1mINSERT INTO "schema_info" (version) VALUES(0)[0m
|
4
|
+
[4;35;1mSQL (0.000224)[0m [0mSELECT version FROM schema_info[0m
|
5
|
+
Migrating to CreateUsers (1)
|
6
|
+
[4;36;1mSQL (0.000223)[0m [0;1m SELECT name
|
7
|
+
FROM sqlite_master
|
8
|
+
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
|
9
|
+
[0m
|
10
|
+
[4;36;1mSQL (0.000428)[0m [0;1mselect sqlite_version(*)[0m
|
11
|
+
[4;35;1mSQL (0.000429)[0m [0mCREATE TABLE "schema_info" (version varchar(255))[0m
|
12
|
+
[4;36;1mSQL (0.000115)[0m [0;1mINSERT INTO "schema_info" (version) VALUES(0)[0m
|
13
|
+
[4;35;1mSQL (0.000221)[0m [0mSELECT version FROM schema_info[0m
|
14
|
+
Migrating to CreateUsers (1)
|
15
|
+
[4;36;1mSQL (0.000359)[0m [0;1mCREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(320) NOT NULL) [0m
|
16
|
+
[4;35;1mSQL (0.000106)[0m [0mUPDATE schema_info SET version = 1[0m
|
17
|
+
[4;36;1mSQL (0.000431)[0m [0;1mselect sqlite_version(*)[0m
|
18
|
+
[4;35;1mSQL (0.000426)[0m [0mCREATE TABLE "schema_info" (version varchar(255))[0m
|
19
|
+
[4;36;1mSQL (0.000114)[0m [0;1mINSERT INTO "schema_info" (version) VALUES(0)[0m
|
20
|
+
[4;35;1mSQL (0.000224)[0m [0mSELECT version FROM schema_info[0m
|
21
|
+
Migrating to CreateUsers (1)
|
22
|
+
[4;36;1mSQL (0.000352)[0m [0;1mCREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(320) NOT NULL) [0m
|
23
|
+
[4;35;1mSQL (0.000105)[0m [0mUPDATE schema_info SET version = 1[0m
|
24
|
+
[4;36;1mSQL (0.000460)[0m [0;1m SELECT name
|
25
|
+
FROM sqlite_master
|
26
|
+
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
|
27
|
+
[0m
|
28
|
+
[4;35;1mSQL (0.000260)[0m [0mselect sqlite_version(*)[0m
|
29
|
+
[4;36;1mSQL (0.000324)[0m [0;1mCREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) [0m
|
30
|
+
[4;35;1mSQL (0.000255)[0m [0mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
31
|
+
[4;36;1mSQL (0.000211)[0m [0;1m SELECT name
|
32
|
+
FROM sqlite_master
|
33
|
+
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
|
34
|
+
[0m
|
35
|
+
[4;35;1mSQL (0.000150)[0m [0mSELECT version FROM schema_migrations[0m
|
36
|
+
Migrating to CreateUsers (1)
|
37
|
+
[4;36;1mSQL (0.000093)[0m [0;1mSELECT version FROM schema_migrations[0m
|
38
|
+
[4;35;1mSQL (0.000361)[0m [0mCREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(320) NOT NULL) [0m
|
39
|
+
[4;36;1mSQL (0.000151)[0m [0;1mINSERT INTO schema_migrations (version) VALUES ('1')[0m
|
data/test/test_helper.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
|
-
|
1
|
+
# Load the plugin testing framework
|
2
|
+
$:.unshift("#{File.dirname(__FILE__)}/../../plugin_test_helper/lib")
|
2
3
|
require 'rubygems'
|
3
|
-
require '
|
4
|
+
require 'plugin_test_helper'
|
4
5
|
|
5
|
-
|
6
|
-
|
6
|
+
# Run the migrations
|
7
|
+
ActiveRecord::Migrator.migrate("#{RAILS_ROOT}/db/migrate")
|
@@ -1,16 +1,7 @@
|
|
1
|
-
require File.dirname(__FILE__) + '
|
2
|
-
|
3
|
-
class User < ActiveRecord::Base
|
4
|
-
def self.columns
|
5
|
-
[]
|
6
|
-
end
|
7
|
-
|
8
|
-
attr_accessor :email
|
9
|
-
validates_as_email_address :email
|
10
|
-
end
|
1
|
+
require File.dirname(__FILE__) + '/../test_helper'
|
11
2
|
|
12
3
|
class ValidatesAsEmailAddressTest < Test::Unit::TestCase
|
13
|
-
def
|
4
|
+
def test_should_require_legal_rfc822_format
|
14
5
|
[
|
15
6
|
'Max@Job 3:14',
|
16
7
|
'Job@Book of Job',
|
@@ -18,9 +9,7 @@ class ValidatesAsEmailAddressTest < Test::Unit::TestCase
|
|
18
9
|
].each do |address|
|
19
10
|
assert !User.new(:email => address).valid?, "#{address} should be illegal."
|
20
11
|
end
|
21
|
-
|
22
|
-
|
23
|
-
def test_legal_rfc822_email_address_should_be_valid
|
12
|
+
|
24
13
|
[
|
25
14
|
'test@example',
|
26
15
|
'test@example.com',
|
@@ -32,4 +21,9 @@ class ValidatesAsEmailAddressTest < Test::Unit::TestCase
|
|
32
21
|
assert User.new(:email => address).valid?, "#{address} should be legal."
|
33
22
|
end
|
34
23
|
end
|
24
|
+
|
25
|
+
def test_not_allow_email_addresses_longer_than_320_characters
|
26
|
+
assert User.new(:email => 'a' * 314 + '@a.com').valid?
|
27
|
+
assert !User.new(:email => 'a' * 315 + '@a.com').valid?
|
28
|
+
end
|
35
29
|
end
|
metadata
CHANGED
@@ -1,53 +1,72 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
|
-
rubygems_version: 0.9.4
|
3
|
-
specification_version: 1
|
4
2
|
name: validates_as_email_address
|
5
3
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.0.
|
7
|
-
date: 2007-09-26 00:00:00 -04:00
|
8
|
-
summary: Adds support for validating the format/length of email addresses
|
9
|
-
require_paths:
|
10
|
-
- lib
|
11
|
-
email: info@pluginaweek.org
|
12
|
-
homepage: http://www.pluginaweek.org
|
13
|
-
rubyforge_project:
|
14
|
-
description:
|
15
|
-
autorequire: validates_as_email_address
|
16
|
-
default_executable:
|
17
|
-
bindir: bin
|
18
|
-
has_rdoc: true
|
19
|
-
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
20
|
-
requirements:
|
21
|
-
- - ">"
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version: 0.0.0
|
24
|
-
version:
|
4
|
+
version: 0.0.2
|
25
5
|
platform: ruby
|
26
|
-
signing_key:
|
27
|
-
cert_chain:
|
28
|
-
post_install_message:
|
29
6
|
authors:
|
30
|
-
- Aaron Pfeifer
|
7
|
+
- Aaron Pfeifer
|
8
|
+
autorequire: validates_as_email_address
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
|
12
|
+
date: 2008-05-05 00:00:00 -04:00
|
13
|
+
default_executable:
|
14
|
+
dependencies: []
|
15
|
+
|
16
|
+
description:
|
17
|
+
email: aaron@pluginaweek.org
|
18
|
+
executables: []
|
19
|
+
|
20
|
+
extensions: []
|
21
|
+
|
22
|
+
extra_rdoc_files: []
|
23
|
+
|
31
24
|
files:
|
32
25
|
- lib/validates_as_email_address.rb
|
26
|
+
- lib/validates_as_email_address
|
27
|
+
- lib/validates_as_email_address/rfc_822.rb
|
28
|
+
- test/app_root
|
29
|
+
- test/app_root/log
|
30
|
+
- test/app_root/log/in_memory.log
|
31
|
+
- test/app_root/db
|
32
|
+
- test/app_root/db/migrate
|
33
|
+
- test/app_root/db/migrate/001_create_users.rb
|
34
|
+
- test/app_root/app
|
35
|
+
- test/app_root/app/models
|
36
|
+
- test/app_root/app/models/user.rb
|
33
37
|
- test/test_helper.rb
|
34
|
-
- test/
|
38
|
+
- test/unit
|
39
|
+
- test/unit/validates_as_email_address_test.rb
|
35
40
|
- CHANGELOG
|
36
41
|
- init.rb
|
37
42
|
- LICENSE
|
38
43
|
- Rakefile
|
39
44
|
- README
|
40
|
-
|
41
|
-
|
45
|
+
has_rdoc: true
|
46
|
+
homepage: http://www.pluginaweek.org
|
47
|
+
post_install_message:
|
42
48
|
rdoc_options: []
|
43
49
|
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
+
require_paths:
|
51
|
+
- lib
|
52
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
53
|
+
requirements:
|
54
|
+
- - ">="
|
55
|
+
- !ruby/object:Gem::Version
|
56
|
+
version: "0"
|
57
|
+
version:
|
58
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
59
|
+
requirements:
|
60
|
+
- - ">="
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: "0"
|
63
|
+
version:
|
50
64
|
requirements: []
|
51
65
|
|
52
|
-
|
53
|
-
|
66
|
+
rubyforge_project:
|
67
|
+
rubygems_version: 1.1.0
|
68
|
+
signing_key:
|
69
|
+
specification_version: 2
|
70
|
+
summary: Adds support for validating the format/length of email addresses
|
71
|
+
test_files:
|
72
|
+
- test/unit/validates_as_email_address_test.rb
|