mongomodel 0.1

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.
Files changed (108) hide show
  1. data/LICENSE +22 -0
  2. data/README.md +34 -0
  3. data/Rakefile +47 -0
  4. data/bin/console +45 -0
  5. data/lib/mongomodel.rb +92 -0
  6. data/lib/mongomodel/attributes/mongo.rb +40 -0
  7. data/lib/mongomodel/attributes/store.rb +30 -0
  8. data/lib/mongomodel/attributes/typecasting.rb +51 -0
  9. data/lib/mongomodel/concerns/abstract_class.rb +17 -0
  10. data/lib/mongomodel/concerns/activemodel.rb +11 -0
  11. data/lib/mongomodel/concerns/associations.rb +103 -0
  12. data/lib/mongomodel/concerns/associations/base/association.rb +33 -0
  13. data/lib/mongomodel/concerns/associations/base/definition.rb +56 -0
  14. data/lib/mongomodel/concerns/associations/base/proxy.rb +58 -0
  15. data/lib/mongomodel/concerns/associations/belongs_to.rb +68 -0
  16. data/lib/mongomodel/concerns/associations/has_many_by_foreign_key.rb +159 -0
  17. data/lib/mongomodel/concerns/associations/has_many_by_ids.rb +175 -0
  18. data/lib/mongomodel/concerns/attribute_methods.rb +55 -0
  19. data/lib/mongomodel/concerns/attribute_methods/before_type_cast.rb +29 -0
  20. data/lib/mongomodel/concerns/attribute_methods/dirty.rb +35 -0
  21. data/lib/mongomodel/concerns/attribute_methods/protected.rb +127 -0
  22. data/lib/mongomodel/concerns/attribute_methods/query.rb +22 -0
  23. data/lib/mongomodel/concerns/attribute_methods/read.rb +29 -0
  24. data/lib/mongomodel/concerns/attribute_methods/write.rb +29 -0
  25. data/lib/mongomodel/concerns/attributes.rb +85 -0
  26. data/lib/mongomodel/concerns/callbacks.rb +294 -0
  27. data/lib/mongomodel/concerns/logging.rb +15 -0
  28. data/lib/mongomodel/concerns/pretty_inspect.rb +29 -0
  29. data/lib/mongomodel/concerns/properties.rb +69 -0
  30. data/lib/mongomodel/concerns/record_status.rb +42 -0
  31. data/lib/mongomodel/concerns/timestamps.rb +32 -0
  32. data/lib/mongomodel/concerns/validations.rb +38 -0
  33. data/lib/mongomodel/concerns/validations/associated.rb +46 -0
  34. data/lib/mongomodel/document.rb +20 -0
  35. data/lib/mongomodel/document/callbacks.rb +46 -0
  36. data/lib/mongomodel/document/dynamic_finders.rb +88 -0
  37. data/lib/mongomodel/document/finders.rb +82 -0
  38. data/lib/mongomodel/document/indexes.rb +91 -0
  39. data/lib/mongomodel/document/optimistic_locking.rb +48 -0
  40. data/lib/mongomodel/document/persistence.rb +143 -0
  41. data/lib/mongomodel/document/scopes.rb +161 -0
  42. data/lib/mongomodel/document/validations.rb +68 -0
  43. data/lib/mongomodel/document/validations/uniqueness.rb +78 -0
  44. data/lib/mongomodel/embedded_document.rb +42 -0
  45. data/lib/mongomodel/locale/en.yml +55 -0
  46. data/lib/mongomodel/support/collection.rb +109 -0
  47. data/lib/mongomodel/support/configuration.rb +35 -0
  48. data/lib/mongomodel/support/core_extensions.rb +10 -0
  49. data/lib/mongomodel/support/exceptions.rb +25 -0
  50. data/lib/mongomodel/support/mongo_options.rb +177 -0
  51. data/lib/mongomodel/support/types.rb +35 -0
  52. data/lib/mongomodel/support/types/array.rb +11 -0
  53. data/lib/mongomodel/support/types/boolean.rb +25 -0
  54. data/lib/mongomodel/support/types/custom.rb +38 -0
  55. data/lib/mongomodel/support/types/date.rb +20 -0
  56. data/lib/mongomodel/support/types/float.rb +13 -0
  57. data/lib/mongomodel/support/types/hash.rb +18 -0
  58. data/lib/mongomodel/support/types/integer.rb +13 -0
  59. data/lib/mongomodel/support/types/object.rb +21 -0
  60. data/lib/mongomodel/support/types/string.rb +9 -0
  61. data/lib/mongomodel/support/types/symbol.rb +9 -0
  62. data/lib/mongomodel/support/types/time.rb +12 -0
  63. data/lib/mongomodel/version.rb +3 -0
  64. data/spec/mongomodel/attributes/store_spec.rb +273 -0
  65. data/spec/mongomodel/concerns/activemodel_spec.rb +61 -0
  66. data/spec/mongomodel/concerns/associations/belongs_to_spec.rb +153 -0
  67. data/spec/mongomodel/concerns/associations/has_many_by_foreign_key_spec.rb +165 -0
  68. data/spec/mongomodel/concerns/associations/has_many_by_ids_spec.rb +192 -0
  69. data/spec/mongomodel/concerns/attribute_methods/before_type_cast_spec.rb +46 -0
  70. data/spec/mongomodel/concerns/attribute_methods/dirty_spec.rb +131 -0
  71. data/spec/mongomodel/concerns/attribute_methods/protected_spec.rb +86 -0
  72. data/spec/mongomodel/concerns/attribute_methods/query_spec.rb +27 -0
  73. data/spec/mongomodel/concerns/attribute_methods/read_spec.rb +52 -0
  74. data/spec/mongomodel/concerns/attribute_methods/write_spec.rb +43 -0
  75. data/spec/mongomodel/concerns/attributes_spec.rb +152 -0
  76. data/spec/mongomodel/concerns/callbacks_spec.rb +90 -0
  77. data/spec/mongomodel/concerns/logging_spec.rb +20 -0
  78. data/spec/mongomodel/concerns/pretty_inspect_spec.rb +68 -0
  79. data/spec/mongomodel/concerns/properties_spec.rb +29 -0
  80. data/spec/mongomodel/concerns/timestamps_spec.rb +170 -0
  81. data/spec/mongomodel/concerns/validations_spec.rb +159 -0
  82. data/spec/mongomodel/document/callbacks_spec.rb +80 -0
  83. data/spec/mongomodel/document/dynamic_finders_spec.rb +183 -0
  84. data/spec/mongomodel/document/finders_spec.rb +231 -0
  85. data/spec/mongomodel/document/indexes_spec.rb +121 -0
  86. data/spec/mongomodel/document/optimistic_locking_spec.rb +57 -0
  87. data/spec/mongomodel/document/persistence_spec.rb +319 -0
  88. data/spec/mongomodel/document/scopes_spec.rb +204 -0
  89. data/spec/mongomodel/document/validations/uniqueness_spec.rb +217 -0
  90. data/spec/mongomodel/document/validations_spec.rb +132 -0
  91. data/spec/mongomodel/document_spec.rb +74 -0
  92. data/spec/mongomodel/embedded_document_spec.rb +66 -0
  93. data/spec/mongomodel/mongomodel_spec.rb +33 -0
  94. data/spec/mongomodel/support/collection_spec.rb +248 -0
  95. data/spec/mongomodel/support/mongo_options_spec.rb +295 -0
  96. data/spec/mongomodel/support/property_spec.rb +83 -0
  97. data/spec/spec.opts +6 -0
  98. data/spec/spec_helper.rb +21 -0
  99. data/spec/specdoc.opts +6 -0
  100. data/spec/support/callbacks.rb +44 -0
  101. data/spec/support/helpers/define_class.rb +24 -0
  102. data/spec/support/helpers/specs_for.rb +11 -0
  103. data/spec/support/matchers/be_a_subclass_of.rb +5 -0
  104. data/spec/support/matchers/respond_to_boolean.rb +17 -0
  105. data/spec/support/matchers/run_callbacks.rb +20 -0
  106. data/spec/support/models.rb +23 -0
  107. data/spec/support/time.rb +6 -0
  108. metadata +232 -0
@@ -0,0 +1,83 @@
1
+ require 'spec_helper'
2
+
3
+ module MongoModel
4
+ module Properties
5
+ describe Property do
6
+ context "no options" do
7
+ subject { Property.new(:name, String) }
8
+
9
+ it "should set property name" do
10
+ subject.name.should == :name
11
+ end
12
+
13
+ it "should set property type" do
14
+ subject.type.should == String
15
+ end
16
+
17
+ it "should set default as value from name" do
18
+ subject.as.should == 'name'
19
+ end
20
+
21
+ it "should default to nil" do
22
+ subject.default(mock('document instance')).should be_nil
23
+ end
24
+
25
+ it "should equal a property with the same name and type" do
26
+ subject.should == Property.new(:name, String)
27
+ end
28
+
29
+ it "should not equal properties with different name, type and options" do
30
+ subject.should_not == Property.new(:address, String)
31
+ subject.should_not == Property.new(:name, Float)
32
+ subject.should_not == Property.new(:name, String, :default => 'Anonymous')
33
+ end
34
+
35
+ it { should_not be_internal }
36
+ end
37
+
38
+ context "with options" do
39
+ subject { Property.new(:age, Integer, :as => '_record_age', :default => 21) }
40
+
41
+ it "should set property options" do
42
+ subject.options.should == { :as => '_record_age', :default => 21 }
43
+ end
44
+
45
+ it "should set custom as value" do
46
+ subject.as.should == '_record_age'
47
+ end
48
+
49
+ it "should default to custom default" do
50
+ subject.default(mock('document instance')).should == 21
51
+ end
52
+
53
+ it "should equal a property with the same name, type and options" do
54
+ subject.should == Property.new(:age, Integer, :as => '_record_age', :default => 21)
55
+ end
56
+
57
+ it "should not equal properties with different name, type and options" do
58
+ subject.should_not == Property.new(:address, String)
59
+ subject.should_not == Property.new(:name, Float)
60
+ subject.should_not == Property.new(:name, String, :default => 'Anonymous')
61
+ end
62
+
63
+ context "with callable default" do
64
+ subject { Property.new(:age, Integer, :default => lambda { |doc| doc.answer }) }
65
+
66
+ it "should call lambda with given instance" do
67
+ subject.default(mock('document instance', :answer => 42)).should == 42
68
+ end
69
+ end
70
+
71
+ context "with internal option" do
72
+ subject { Property.new(:age, Integer, :internal => true) }
73
+ it { should be_internal }
74
+ end
75
+
76
+ context "with internal property name" do
77
+ subject { Property.new(:age, Integer, :as => '_age') }
78
+ it { should be_internal }
79
+ end
80
+ end
81
+ end
82
+ end
83
+ end
@@ -0,0 +1,6 @@
1
+ --colour
2
+ --format
3
+ progress
4
+ --loadby
5
+ mtime
6
+ --reverse
@@ -0,0 +1,21 @@
1
+ require 'rubygems'
2
+ require 'spec'
3
+
4
+ # Require MongoModel library
5
+ require File.dirname(__FILE__) + '/../lib/mongomodel'
6
+
7
+ # Require spec helpers
8
+ Dir[File.dirname(__FILE__) + "/support/**/*.rb"].each { |f| require f }
9
+
10
+ Spec::Runner.configure do |config|
11
+ include SpecsFor
12
+ include DefineClass
13
+
14
+ config.before(:all) do
15
+ MongoModel.configuration = { 'database' => 'mongomodel-specs' }
16
+ end
17
+
18
+ config.before(:each) do
19
+ MongoModel.database.collections.each { |c| c.drop }
20
+ end
21
+ end
@@ -0,0 +1,6 @@
1
+ --colour
2
+ --format
3
+ nested
4
+ --loadby
5
+ mtime
6
+ --reverse
@@ -0,0 +1,44 @@
1
+ module MongoModel
2
+ module CallbackHelpers
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ MongoModel::Callbacks::CALLBACKS.each do |callback_method|
7
+ next if callback_method.to_s =~ /^around_/
8
+ define_callback_method(callback_method)
9
+ send(callback_method, callback_string(callback_method))
10
+ send(callback_method, callback_proc(callback_method))
11
+ send(callback_method, callback_object(callback_method))
12
+ send(callback_method) { |model| model.history << [callback_method, :block] }
13
+ end
14
+ end
15
+
16
+ module ClassMethods
17
+ def callback_string(callback_method)
18
+ "history << [#{callback_method.to_sym.inspect}, :string]"
19
+ end
20
+
21
+ def callback_proc(callback_method)
22
+ Proc.new { |model| model.history << [callback_method, :proc] }
23
+ end
24
+
25
+ def define_callback_method(callback_method)
26
+ define_method("#{callback_method}_method") do |model|
27
+ model.history << [callback_method, :method]
28
+ end
29
+ end
30
+
31
+ def callback_object(callback_method)
32
+ klass = Class.new
33
+ klass.send(:define_method, callback_method) do |model|
34
+ model.history << [callback_method, :object]
35
+ end
36
+ klass.new
37
+ end
38
+ end
39
+
40
+ def history
41
+ @history ||= []
42
+ end
43
+ end
44
+ end
@@ -0,0 +1,24 @@
1
+ require 'active_support/core_ext/string/inflections'
2
+
3
+ module DefineClass
4
+ def define_class(name, parent_class=nil, &block)
5
+ before(:each) do
6
+ Thread.current[:"#{name}_scopes"] = nil
7
+ Object.send(:remove_const, name) if Object.const_defined?(name)
8
+
9
+ case parent_class
10
+ when Class
11
+ klass = Class.new(parent_class)
12
+ when String, Symbol
13
+ klass = Class.new(parent_class.to_s.constantize)
14
+ when nil
15
+ klass = Class.new
16
+ end
17
+
18
+ Object.const_set(name, klass)
19
+
20
+ klass.class_eval(&block) if block_given?
21
+ klass
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,11 @@
1
+ module SpecsFor
2
+ def specs_for(*klasses, &block)
3
+ klasses.each do |klass|
4
+ describe(klass, &block)
5
+ end
6
+ end
7
+
8
+ def specing?(klass)
9
+ described_class == klass
10
+ end
11
+ end
@@ -0,0 +1,5 @@
1
+ Spec::Matchers.define(:be_a_subclass_of) do |ancestor|
2
+ match do |klass|
3
+ klass.ancestors.include?(ancestor)
4
+ end
5
+ end
@@ -0,0 +1,17 @@
1
+ Spec::Matchers.define(:respond_to_boolean) do |method|
2
+ match do |instance|
3
+ instance.respond_to?(method) && is_boolean?(instance.send(method))
4
+ end
5
+
6
+ description do
7
+ "should respond to #{method} and return boolean"
8
+ end
9
+
10
+ failure_message_for_should do |instance|
11
+ "expected #{instance.inspect} to respond to #{method} and return boolean"
12
+ end
13
+
14
+ def is_boolean?(value)
15
+ value == true || value == false
16
+ end
17
+ end
@@ -0,0 +1,20 @@
1
+ Spec::Matchers.define(:run_callbacks) do |*callbacks|
2
+ match do |instance|
3
+ instance.history == expand_callbacks(callbacks)
4
+ end
5
+
6
+ failure_message_for_should do |instance|
7
+ "expected #{instance.inspect} to run callbacks #{callbacks.inspect} but got #{compress_callbacks(instance.history).inspect}"
8
+ end
9
+
10
+ def compress_callbacks(callbacks)
11
+ callbacks.inject([]) { |result, (callback, type)|
12
+ result << callback if type == :string
13
+ result
14
+ }
15
+ end
16
+
17
+ def expand_callbacks(callbacks)
18
+ callbacks.map { |c| [ [c, :string], [c, :proc], [c, :object], [c, :block] ] }.inject([]) { |result, c| result + c }
19
+ end
20
+ end
@@ -0,0 +1,23 @@
1
+ class CustomClass
2
+ attr_reader :name
3
+
4
+ def initialize(name)
5
+ @name = name
6
+ end
7
+
8
+ def ==(other)
9
+ other.is_a?(self.class) && name == other.name
10
+ end
11
+
12
+ def to_mongo
13
+ { :name => name }
14
+ end
15
+
16
+ def self.from_mongo(hash)
17
+ new(hash[:name])
18
+ end
19
+
20
+ def self.cast(value)
21
+ new(value.to_s)
22
+ end
23
+ end
@@ -0,0 +1,6 @@
1
+ # For the purposes of tests, we ignore fractions of a second when comparing Time objects
2
+ class Time
3
+ def ==(other)
4
+ super(other) || utc.to_s == other.utc.to_s if other
5
+ end
6
+ end
metadata ADDED
@@ -0,0 +1,232 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mongomodel
3
+ version: !ruby/object:Gem::Version
4
+ version: "0.1"
5
+ platform: ruby
6
+ authors:
7
+ - Sam Pohlenz
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2010-01-27 00:00:00 +10:30
13
+ default_executable: console
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: activesupport
17
+ type: :runtime
18
+ version_requirement:
19
+ version_requirements: !ruby/object:Gem::Requirement
20
+ requirements:
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: 3.0.pre
24
+ version:
25
+ - !ruby/object:Gem::Dependency
26
+ name: activemodel
27
+ type: :runtime
28
+ version_requirement:
29
+ version_requirements: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 3.0.pre
34
+ version:
35
+ - !ruby/object:Gem::Dependency
36
+ name: mongo
37
+ type: :runtime
38
+ version_requirement:
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: 0.18.3
44
+ version:
45
+ description: MongoModel is a MongoDB ORM for Ruby/Rails similar to ActiveRecord, DataMapper.
46
+ email: sam@sampohlenz.com
47
+ executables:
48
+ - console
49
+ extensions: []
50
+
51
+ extra_rdoc_files:
52
+ - LICENSE
53
+ - README.md
54
+ files:
55
+ - LICENSE
56
+ - README.md
57
+ - Rakefile
58
+ - bin/console
59
+ - lib/mongomodel.rb
60
+ - lib/mongomodel/attributes/mongo.rb
61
+ - lib/mongomodel/attributes/store.rb
62
+ - lib/mongomodel/attributes/typecasting.rb
63
+ - lib/mongomodel/concerns/abstract_class.rb
64
+ - lib/mongomodel/concerns/activemodel.rb
65
+ - lib/mongomodel/concerns/associations.rb
66
+ - lib/mongomodel/concerns/associations/base/association.rb
67
+ - lib/mongomodel/concerns/associations/base/definition.rb
68
+ - lib/mongomodel/concerns/associations/base/proxy.rb
69
+ - lib/mongomodel/concerns/associations/belongs_to.rb
70
+ - lib/mongomodel/concerns/associations/has_many_by_foreign_key.rb
71
+ - lib/mongomodel/concerns/associations/has_many_by_ids.rb
72
+ - lib/mongomodel/concerns/attribute_methods.rb
73
+ - lib/mongomodel/concerns/attribute_methods/before_type_cast.rb
74
+ - lib/mongomodel/concerns/attribute_methods/dirty.rb
75
+ - lib/mongomodel/concerns/attribute_methods/protected.rb
76
+ - lib/mongomodel/concerns/attribute_methods/query.rb
77
+ - lib/mongomodel/concerns/attribute_methods/read.rb
78
+ - lib/mongomodel/concerns/attribute_methods/write.rb
79
+ - lib/mongomodel/concerns/attributes.rb
80
+ - lib/mongomodel/concerns/callbacks.rb
81
+ - lib/mongomodel/concerns/logging.rb
82
+ - lib/mongomodel/concerns/pretty_inspect.rb
83
+ - lib/mongomodel/concerns/properties.rb
84
+ - lib/mongomodel/concerns/record_status.rb
85
+ - lib/mongomodel/concerns/timestamps.rb
86
+ - lib/mongomodel/concerns/validations.rb
87
+ - lib/mongomodel/concerns/validations/associated.rb
88
+ - lib/mongomodel/document.rb
89
+ - lib/mongomodel/document/callbacks.rb
90
+ - lib/mongomodel/document/dynamic_finders.rb
91
+ - lib/mongomodel/document/finders.rb
92
+ - lib/mongomodel/document/indexes.rb
93
+ - lib/mongomodel/document/optimistic_locking.rb
94
+ - lib/mongomodel/document/persistence.rb
95
+ - lib/mongomodel/document/scopes.rb
96
+ - lib/mongomodel/document/validations.rb
97
+ - lib/mongomodel/document/validations/uniqueness.rb
98
+ - lib/mongomodel/embedded_document.rb
99
+ - lib/mongomodel/locale/en.yml
100
+ - lib/mongomodel/support/collection.rb
101
+ - lib/mongomodel/support/configuration.rb
102
+ - lib/mongomodel/support/core_extensions.rb
103
+ - lib/mongomodel/support/exceptions.rb
104
+ - lib/mongomodel/support/mongo_options.rb
105
+ - lib/mongomodel/support/types.rb
106
+ - lib/mongomodel/support/types/array.rb
107
+ - lib/mongomodel/support/types/boolean.rb
108
+ - lib/mongomodel/support/types/custom.rb
109
+ - lib/mongomodel/support/types/date.rb
110
+ - lib/mongomodel/support/types/float.rb
111
+ - lib/mongomodel/support/types/hash.rb
112
+ - lib/mongomodel/support/types/integer.rb
113
+ - lib/mongomodel/support/types/object.rb
114
+ - lib/mongomodel/support/types/string.rb
115
+ - lib/mongomodel/support/types/symbol.rb
116
+ - lib/mongomodel/support/types/time.rb
117
+ - lib/mongomodel/version.rb
118
+ - spec/mongomodel/attributes/store_spec.rb
119
+ - spec/mongomodel/concerns/activemodel_spec.rb
120
+ - spec/mongomodel/concerns/associations/belongs_to_spec.rb
121
+ - spec/mongomodel/concerns/associations/has_many_by_foreign_key_spec.rb
122
+ - spec/mongomodel/concerns/associations/has_many_by_ids_spec.rb
123
+ - spec/mongomodel/concerns/attribute_methods/before_type_cast_spec.rb
124
+ - spec/mongomodel/concerns/attribute_methods/dirty_spec.rb
125
+ - spec/mongomodel/concerns/attribute_methods/protected_spec.rb
126
+ - spec/mongomodel/concerns/attribute_methods/query_spec.rb
127
+ - spec/mongomodel/concerns/attribute_methods/read_spec.rb
128
+ - spec/mongomodel/concerns/attribute_methods/write_spec.rb
129
+ - spec/mongomodel/concerns/attributes_spec.rb
130
+ - spec/mongomodel/concerns/callbacks_spec.rb
131
+ - spec/mongomodel/concerns/logging_spec.rb
132
+ - spec/mongomodel/concerns/pretty_inspect_spec.rb
133
+ - spec/mongomodel/concerns/properties_spec.rb
134
+ - spec/mongomodel/concerns/timestamps_spec.rb
135
+ - spec/mongomodel/concerns/validations_spec.rb
136
+ - spec/mongomodel/document/callbacks_spec.rb
137
+ - spec/mongomodel/document/dynamic_finders_spec.rb
138
+ - spec/mongomodel/document/finders_spec.rb
139
+ - spec/mongomodel/document/indexes_spec.rb
140
+ - spec/mongomodel/document/optimistic_locking_spec.rb
141
+ - spec/mongomodel/document/persistence_spec.rb
142
+ - spec/mongomodel/document/scopes_spec.rb
143
+ - spec/mongomodel/document/validations/uniqueness_spec.rb
144
+ - spec/mongomodel/document/validations_spec.rb
145
+ - spec/mongomodel/document_spec.rb
146
+ - spec/mongomodel/embedded_document_spec.rb
147
+ - spec/mongomodel/mongomodel_spec.rb
148
+ - spec/mongomodel/support/collection_spec.rb
149
+ - spec/mongomodel/support/mongo_options_spec.rb
150
+ - spec/mongomodel/support/property_spec.rb
151
+ - spec/spec.opts
152
+ - spec/spec_helper.rb
153
+ - spec/specdoc.opts
154
+ - spec/support/callbacks.rb
155
+ - spec/support/helpers/define_class.rb
156
+ - spec/support/helpers/specs_for.rb
157
+ - spec/support/matchers/be_a_subclass_of.rb
158
+ - spec/support/matchers/respond_to_boolean.rb
159
+ - spec/support/matchers/run_callbacks.rb
160
+ - spec/support/models.rb
161
+ - spec/support/time.rb
162
+ has_rdoc: true
163
+ homepage: http://github.com/spohlenz/mongomodel
164
+ licenses: []
165
+
166
+ post_install_message:
167
+ rdoc_options:
168
+ - --charset=UTF-8
169
+ require_paths:
170
+ - lib
171
+ required_ruby_version: !ruby/object:Gem::Requirement
172
+ requirements:
173
+ - - ">="
174
+ - !ruby/object:Gem::Version
175
+ version: "0"
176
+ version:
177
+ required_rubygems_version: !ruby/object:Gem::Requirement
178
+ requirements:
179
+ - - ">="
180
+ - !ruby/object:Gem::Version
181
+ version: "0"
182
+ version:
183
+ requirements: []
184
+
185
+ rubyforge_project:
186
+ rubygems_version: 1.3.5
187
+ signing_key:
188
+ specification_version: 3
189
+ summary: MongoDB ORM for Ruby/Rails
190
+ test_files:
191
+ - spec/mongomodel/attributes/store_spec.rb
192
+ - spec/mongomodel/concerns/activemodel_spec.rb
193
+ - spec/mongomodel/concerns/associations/belongs_to_spec.rb
194
+ - spec/mongomodel/concerns/associations/has_many_by_foreign_key_spec.rb
195
+ - spec/mongomodel/concerns/associations/has_many_by_ids_spec.rb
196
+ - spec/mongomodel/concerns/attribute_methods/before_type_cast_spec.rb
197
+ - spec/mongomodel/concerns/attribute_methods/dirty_spec.rb
198
+ - spec/mongomodel/concerns/attribute_methods/protected_spec.rb
199
+ - spec/mongomodel/concerns/attribute_methods/query_spec.rb
200
+ - spec/mongomodel/concerns/attribute_methods/read_spec.rb
201
+ - spec/mongomodel/concerns/attribute_methods/write_spec.rb
202
+ - spec/mongomodel/concerns/attributes_spec.rb
203
+ - spec/mongomodel/concerns/callbacks_spec.rb
204
+ - spec/mongomodel/concerns/logging_spec.rb
205
+ - spec/mongomodel/concerns/pretty_inspect_spec.rb
206
+ - spec/mongomodel/concerns/properties_spec.rb
207
+ - spec/mongomodel/concerns/timestamps_spec.rb
208
+ - spec/mongomodel/concerns/validations_spec.rb
209
+ - spec/mongomodel/document/callbacks_spec.rb
210
+ - spec/mongomodel/document/dynamic_finders_spec.rb
211
+ - spec/mongomodel/document/finders_spec.rb
212
+ - spec/mongomodel/document/indexes_spec.rb
213
+ - spec/mongomodel/document/optimistic_locking_spec.rb
214
+ - spec/mongomodel/document/persistence_spec.rb
215
+ - spec/mongomodel/document/scopes_spec.rb
216
+ - spec/mongomodel/document/validations/uniqueness_spec.rb
217
+ - spec/mongomodel/document/validations_spec.rb
218
+ - spec/mongomodel/document_spec.rb
219
+ - spec/mongomodel/embedded_document_spec.rb
220
+ - spec/mongomodel/mongomodel_spec.rb
221
+ - spec/mongomodel/support/collection_spec.rb
222
+ - spec/mongomodel/support/mongo_options_spec.rb
223
+ - spec/mongomodel/support/property_spec.rb
224
+ - spec/spec_helper.rb
225
+ - spec/support/callbacks.rb
226
+ - spec/support/helpers/define_class.rb
227
+ - spec/support/helpers/specs_for.rb
228
+ - spec/support/matchers/be_a_subclass_of.rb
229
+ - spec/support/matchers/respond_to_boolean.rb
230
+ - spec/support/matchers/run_callbacks.rb
231
+ - spec/support/models.rb
232
+ - spec/support/time.rb