remarkable_activemodel 4.0.0.alpha1 → 4.0.0.alpha2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README +13 -0
- data/lib/remarkable/active_model.rb +14 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/base.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/allow_values_for_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_acceptance_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_confirmation_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_exclusion_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_inclusion_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_length_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_numericality_of_matcher.rb +0 -0
- data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_presence_of_matcher.rb +0 -0
- data/remarkable_activemodel.gemspec +20 -20
- metadata +27 -18
- data/lib/remarkable_activemodel.rb +0 -28
data/README
CHANGED
@@ -25,6 +25,19 @@ Upcoming features:
|
|
25
25
|
This allows you to test for compliance if you are using special serialization
|
26
26
|
methods, or require the use of Presenters in your application.
|
27
27
|
|
28
|
+
== Installation
|
29
|
+
|
30
|
+
sudo gem install remarkable_activemodel --pre
|
31
|
+
|
32
|
+
Add this to your Gemfile:
|
33
|
+
|
34
|
+
group :test do
|
35
|
+
gem 'remarkable_activemodel', '>=4.0.0.alpha2'
|
36
|
+
end
|
37
|
+
|
38
|
+
Drop this into your spec/spec_helper.rb or spec/support/remarkable.rb file:
|
39
|
+
|
40
|
+
require 'remarkable/active_model'
|
28
41
|
|
29
42
|
== Examples
|
30
43
|
|
@@ -0,0 +1,14 @@
|
|
1
|
+
# Load Remarkable
|
2
|
+
require 'remarkable/core'
|
3
|
+
require 'remarkable/active_model/base'
|
4
|
+
|
5
|
+
# Add default locale
|
6
|
+
dir = File.dirname(__FILE__)
|
7
|
+
Dir["#{dir}/../../locale/*yml"].each {|f| Remarkable.add_locale(f) }
|
8
|
+
|
9
|
+
# Add matchers
|
10
|
+
Dir[File.join(dir, 'active_model', 'matchers', '*.rb')].each do |file|
|
11
|
+
require file
|
12
|
+
end
|
13
|
+
|
14
|
+
Remarkable.include_matchers!(Remarkable::ActiveModel, Rspec::Core::ExampleGroup)
|
File without changes
|
data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/allow_values_for_matcher.rb
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_length_of_matcher.rb
RENAMED
File without changes
|
File without changes
|
data/lib/{remarkable_activemodel → remarkable/active_model}/matchers/validate_presence_of_matcher.rb
RENAMED
File without changes
|
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{remarkable_activemodel}
|
8
|
-
s.version = "4.0.0.
|
8
|
+
s.version = "4.0.0.alpha2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Ho-Sheng Hsiao", "Carlos Brando", "Jos\303\251 Valim", "Diego Carrion"]
|
12
|
-
s.date = %q{2010-
|
12
|
+
s.date = %q{2010-05-26}
|
13
13
|
s.description = %q{Remarkable ActiveModel: collection of matchers and macros with I18n for ActiveModel}
|
14
14
|
s.email = ["hosh@sparkfly.com", "eduardobrando@gmail.com", "jose.valim@gmail.com", "dc.rec1@gmail.com"]
|
15
15
|
s.extra_rdoc_files = [
|
@@ -21,16 +21,16 @@ Gem::Specification.new do |s|
|
|
21
21
|
"CHANGELOG",
|
22
22
|
"LICENSE",
|
23
23
|
"README",
|
24
|
-
"lib/
|
25
|
-
"lib/
|
26
|
-
"lib/
|
27
|
-
"lib/
|
28
|
-
"lib/
|
29
|
-
"lib/
|
30
|
-
"lib/
|
31
|
-
"lib/
|
32
|
-
"lib/
|
33
|
-
"lib/
|
24
|
+
"lib/remarkable/active_model.rb",
|
25
|
+
"lib/remarkable/active_model/base.rb",
|
26
|
+
"lib/remarkable/active_model/matchers/allow_values_for_matcher.rb",
|
27
|
+
"lib/remarkable/active_model/matchers/validate_acceptance_of_matcher.rb",
|
28
|
+
"lib/remarkable/active_model/matchers/validate_confirmation_of_matcher.rb",
|
29
|
+
"lib/remarkable/active_model/matchers/validate_exclusion_of_matcher.rb",
|
30
|
+
"lib/remarkable/active_model/matchers/validate_inclusion_of_matcher.rb",
|
31
|
+
"lib/remarkable/active_model/matchers/validate_length_of_matcher.rb",
|
32
|
+
"lib/remarkable/active_model/matchers/validate_numericality_of_matcher.rb",
|
33
|
+
"lib/remarkable/active_model/matchers/validate_presence_of_matcher.rb",
|
34
34
|
"locale/en.yml",
|
35
35
|
"remarkable_activemodel.gemspec",
|
36
36
|
"remarkable_activerecord.gemspec"
|
@@ -39,23 +39,23 @@ Gem::Specification.new do |s|
|
|
39
39
|
s.rdoc_options = ["--charset=UTF-8"]
|
40
40
|
s.require_paths = ["lib"]
|
41
41
|
s.rubyforge_project = %q{remarkable}
|
42
|
-
s.rubygems_version = %q{1.3.
|
42
|
+
s.rubygems_version = %q{1.3.7}
|
43
43
|
s.summary = %q{Remarkable ActiveModel: collection of matchers and macros with I18n for ActiveModel}
|
44
44
|
|
45
45
|
if s.respond_to? :specification_version then
|
46
46
|
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
47
47
|
s.specification_version = 3
|
48
48
|
|
49
|
-
if Gem::Version.new(Gem::
|
50
|
-
s.add_runtime_dependency(%q<rspec>, [">= 2.0.0.
|
51
|
-
s.add_runtime_dependency(%q<remarkable>, ["~> 4.0.0.
|
49
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
50
|
+
s.add_runtime_dependency(%q<rspec>, [">= 2.0.0.alpha8"])
|
51
|
+
s.add_runtime_dependency(%q<remarkable>, ["~> 4.0.0.alpha2"])
|
52
52
|
else
|
53
|
-
s.add_dependency(%q<rspec>, [">= 2.0.0.
|
54
|
-
s.add_dependency(%q<remarkable>, ["~> 4.0.0.
|
53
|
+
s.add_dependency(%q<rspec>, [">= 2.0.0.alpha8"])
|
54
|
+
s.add_dependency(%q<remarkable>, ["~> 4.0.0.alpha2"])
|
55
55
|
end
|
56
56
|
else
|
57
|
-
s.add_dependency(%q<rspec>, [">= 2.0.0.
|
58
|
-
s.add_dependency(%q<remarkable>, ["~> 4.0.0.
|
57
|
+
s.add_dependency(%q<rspec>, [">= 2.0.0.alpha8"])
|
58
|
+
s.add_dependency(%q<remarkable>, ["~> 4.0.0.alpha2"])
|
59
59
|
end
|
60
60
|
end
|
61
61
|
|
metadata
CHANGED
@@ -1,13 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: remarkable_activemodel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
+
hash: -1710980496
|
4
5
|
prerelease: true
|
5
6
|
segments:
|
6
7
|
- 4
|
7
8
|
- 0
|
8
9
|
- 0
|
9
|
-
-
|
10
|
-
version: 4.0.0.
|
10
|
+
- alpha2
|
11
|
+
version: 4.0.0.alpha2
|
11
12
|
platform: ruby
|
12
13
|
authors:
|
13
14
|
- Ho-Sheng Hsiao
|
@@ -18,37 +19,41 @@ autorequire:
|
|
18
19
|
bindir: bin
|
19
20
|
cert_chain: []
|
20
21
|
|
21
|
-
date: 2010-
|
22
|
+
date: 2010-05-26 00:00:00 -04:00
|
22
23
|
default_executable:
|
23
24
|
dependencies:
|
24
25
|
- !ruby/object:Gem::Dependency
|
25
26
|
name: rspec
|
26
27
|
prerelease: false
|
27
28
|
requirement: &id001 !ruby/object:Gem::Requirement
|
29
|
+
none: false
|
28
30
|
requirements:
|
29
31
|
- - ">="
|
30
32
|
- !ruby/object:Gem::Version
|
33
|
+
hash: -1710980374
|
31
34
|
segments:
|
32
35
|
- 2
|
33
36
|
- 0
|
34
37
|
- 0
|
35
|
-
-
|
36
|
-
version: 2.0.0.
|
38
|
+
- alpha8
|
39
|
+
version: 2.0.0.alpha8
|
37
40
|
type: :runtime
|
38
41
|
version_requirements: *id001
|
39
42
|
- !ruby/object:Gem::Dependency
|
40
43
|
name: remarkable
|
41
44
|
prerelease: false
|
42
45
|
requirement: &id002 !ruby/object:Gem::Requirement
|
46
|
+
none: false
|
43
47
|
requirements:
|
44
48
|
- - ~>
|
45
49
|
- !ruby/object:Gem::Version
|
50
|
+
hash: -1710980496
|
46
51
|
segments:
|
47
52
|
- 4
|
48
53
|
- 0
|
49
54
|
- 0
|
50
|
-
-
|
51
|
-
version: 4.0.0.
|
55
|
+
- alpha2
|
56
|
+
version: 4.0.0.alpha2
|
52
57
|
type: :runtime
|
53
58
|
version_requirements: *id002
|
54
59
|
description: "Remarkable ActiveModel: collection of matchers and macros with I18n for ActiveModel"
|
@@ -69,16 +74,16 @@ files:
|
|
69
74
|
- CHANGELOG
|
70
75
|
- LICENSE
|
71
76
|
- README
|
72
|
-
- lib/
|
73
|
-
- lib/
|
74
|
-
- lib/
|
75
|
-
- lib/
|
76
|
-
- lib/
|
77
|
-
- lib/
|
78
|
-
- lib/
|
79
|
-
- lib/
|
80
|
-
- lib/
|
81
|
-
- lib/
|
77
|
+
- lib/remarkable/active_model.rb
|
78
|
+
- lib/remarkable/active_model/base.rb
|
79
|
+
- lib/remarkable/active_model/matchers/allow_values_for_matcher.rb
|
80
|
+
- lib/remarkable/active_model/matchers/validate_acceptance_of_matcher.rb
|
81
|
+
- lib/remarkable/active_model/matchers/validate_confirmation_of_matcher.rb
|
82
|
+
- lib/remarkable/active_model/matchers/validate_exclusion_of_matcher.rb
|
83
|
+
- lib/remarkable/active_model/matchers/validate_inclusion_of_matcher.rb
|
84
|
+
- lib/remarkable/active_model/matchers/validate_length_of_matcher.rb
|
85
|
+
- lib/remarkable/active_model/matchers/validate_numericality_of_matcher.rb
|
86
|
+
- lib/remarkable/active_model/matchers/validate_presence_of_matcher.rb
|
82
87
|
- locale/en.yml
|
83
88
|
- remarkable_activemodel.gemspec
|
84
89
|
- remarkable_activerecord.gemspec
|
@@ -92,16 +97,20 @@ rdoc_options:
|
|
92
97
|
require_paths:
|
93
98
|
- lib
|
94
99
|
required_ruby_version: !ruby/object:Gem::Requirement
|
100
|
+
none: false
|
95
101
|
requirements:
|
96
102
|
- - ">="
|
97
103
|
- !ruby/object:Gem::Version
|
104
|
+
hash: 3
|
98
105
|
segments:
|
99
106
|
- 0
|
100
107
|
version: "0"
|
101
108
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
|
+
none: false
|
102
110
|
requirements:
|
103
111
|
- - ">"
|
104
112
|
- !ruby/object:Gem::Version
|
113
|
+
hash: 25
|
105
114
|
segments:
|
106
115
|
- 1
|
107
116
|
- 3
|
@@ -110,7 +119,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
110
119
|
requirements: []
|
111
120
|
|
112
121
|
rubyforge_project: remarkable
|
113
|
-
rubygems_version: 1.3.
|
122
|
+
rubygems_version: 1.3.7
|
114
123
|
signing_key:
|
115
124
|
specification_version: 3
|
116
125
|
summary: "Remarkable ActiveModel: collection of matchers and macros with I18n for ActiveModel"
|
@@ -1,28 +0,0 @@
|
|
1
|
-
# Load Remarkable
|
2
|
-
unless Object.const_defined?('Remarkable')
|
3
|
-
begin
|
4
|
-
require 'remarkable'
|
5
|
-
rescue LoadError
|
6
|
-
require 'rubygems'
|
7
|
-
gem 'remarkable'
|
8
|
-
require 'remarkable'
|
9
|
-
end
|
10
|
-
end
|
11
|
-
|
12
|
-
# Load Remarkable ActiveModel files
|
13
|
-
dir = File.dirname(__FILE__)
|
14
|
-
require File.join(dir, 'remarkable_activemodel', 'base')
|
15
|
-
|
16
|
-
# Add locale
|
17
|
-
Remarkable.add_locale File.join(dir, '..', 'locale', 'en.yml')
|
18
|
-
|
19
|
-
# Add matchers
|
20
|
-
Dir[File.join(dir, 'remarkable_activemodel', 'matchers', '*.rb')].each do |file|
|
21
|
-
require file
|
22
|
-
end
|
23
|
-
|
24
|
-
# By default, ActiveModel matchers are not included in any example group.
|
25
|
-
# The responsibility for this is RemarkableRails. If you are using ActiveModel
|
26
|
-
# without Rails, put the line below in your spec_helper to include ActiveModel
|
27
|
-
# matchers into rspec globally.
|
28
|
-
# Remarkable.include_matchers!(Remarkable::ActiveModel, Rspec::Example::ExampleGroup)
|