This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Error: | |
test_add_all_modules(ActiveRecordTest): | |
NameError: uninitialized constant ActiveRecordTest::Devisable | |
activesupport (2.3.5) lib/active_support/dependencies.rb:105:in `const_missing' | |
/test/models_test.rb:96:in `test_add_all_modules' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `__send__' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `run' | |
2) Error: | |
test_add_validatable_module_only(ActiveRecordTest): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class User | |
include DataMapper::Resource | |
property :username, String | |
# authenticatable | |
property :email, String | |
property :encrypted_password, String | |
property :password_salt, String |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Error: | |
test_add_all_modules(ActiveRecordTest): | |
NameError: uninitialized constant ActiveRecordTest::Devisable | |
activesupport (2.3.5) lib/active_support/dependencies.rb:105:in `const_missing' | |
/test/models_test.rb:96:in `test_add_all_modules' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `__send__' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `run' | |
2) Error: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Error: | |
test_add_all_modules(ActiveRecordTest): | |
NameError: uninitialized constant ActiveRecordTest::Devisable | |
activesupport (2.3.5) lib/active_support/dependencies.rb:105:in `const_missing' | |
/test/models_test.rb:96:in `test_add_all_modules' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `__send__' | |
activesupport (2.3.5) lib/active_support/testing/setup_and_teardown.rb:62:in `run' | |
2) Error: | |
test_add_validatable_module_only(ActiveRecordTest): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) | |
NoMethodError in 'Single Table Inheritance should have a type property that reflects the class' | |
undefined method `key' for "Person":String | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/model.rb:494:in `load' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/model.rb:482:in `map' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/model.rb:482:in `load' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/repository.rb:145:in `read' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/collection.rb:1111:in `lazy_load' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/extlib-0.9.14/lib/extlib/lazy_array.rb:409:in `each' | |
/Users/lancelotcarlson/.rvm/gems/ruby/1.8.7/gems/dm-core-0.10.3/lib/dm-core/collection.rb:506:in `each' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Single Table Inheritance | |
READ | |
"(id = 4b44589b7d209c282d000001)" | |
READ | |
"(id = 4b44589b7d209c282d000002)" | |
READ | |
"(id = 4b44589b7d209c282d000003)" | |
READ | |
"(id = 4b44589b7d209c282d000004)" | |
- should have a type property that reflects the class |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.join(File.dirname(__FILE__), 'spec_helper') | |
describe "Single Table Inheritance" do | |
before(:all) do | |
cleanup_models :Person, :Male, :Father, :Son | |
$db.drop_collection('people') | |
class ::Person | |
include DataMapper::Mongo::Resource | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Single Table Inheritance | |
#<DataMapper::Query::Conditions::AndOperation:0x163ffdc @operands=#<Set: {#<DataMapper::Query::Conditions::EqualToComparison @subject=#<DataMapper::Property @model=Person @name=:id> @dumped_value=4b44547c7d209c280e000001 @loaded_value="4b44547c7d209c280e000001">}>> | |
#<DataMapper::Query::Conditions::AndOperation:0x163463c @operands=#<Set: {#<DataMapper::Query::Conditions::EqualToComparison @subject=#<DataMapper::Property @model=Person @name=:id> @dumped_value=4b44547c7d209c280e000002 @loaded_value="4b44547c7d209c280e000002">}>> | |
#<DataMapper::Query::Conditions::AndOperation:0x1628cc4 @operands=#<Set: {#<DataMapper::Query::Conditions::EqualToComparison @subject=#<DataMapper::Property @model=Person @name=:id> @dumped_value=4b44547c7d209c280e000003 @loaded_value="4b44547c7d209c280e000003">}>> | |
#<DataMapper::Query::Conditions::AndOperation:0x161d34c @operands=#<Set: {#<DataMapper::Query::Conditions::EqualToComparison @subject=#<DataMapper::Property @model=Person @name=:id> @dumped_value=4b445 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lance-carlsons-macbook-pro:clojure lancelotcarlson$ ant | |
Buildfile: build.xml | |
init: | |
compile_java: | |
compile_clojure: | |
[java] Compiling clojure.core to /Users/lancelotcarlson/src/clojure/classes | |
[java] Compiling clojure.main to /Users/lancelotcarlson/src/clojure/classes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(use 'compojure) | |
(defroutes my-app | |
(GET "/" | |
(html [:h1 "Hello World"])) | |
(ANY "*" | |
(page-not-found))) | |
(run-server {:port 8080} |