Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

ruby 1.9 #1

Open
reactormonk opened this Issue Mar 19, 2010 · 1 comment

Comments

Projects
None yet
2 participants

Ehm.

  1)
  'LightMongo::Document::Serialization#export if Persistence has been included generates a hash of its class name and id' FAILED
  expected: {"_class_name"=>"TestClass", "_id"=>#<Spec::Mocks::Mock:0x18c34e8 @name=:id>},
       got: {"_class_name"=>"#<Class:0x000000031a4678>::TestClass", "_id"=>#<Spec::Mocks::Mock:0x18c34e8 @name=:id>} (using ==)
  /tmp/light_mongo/spec/document/serialization_spec.rb:34:in `block (4 levels) in <top (required)>'

  2)
  NoMethodError in 'LightMongo::Document::Serialization::HashSerializer.serialize_object(object_to_serialize, current_depth) when a non-primitive non-LightMongo::Document object hashifies the object'
  undefined method `sub' for :@name:Symbol
  /tmp/light_mongo/spec/document/serialization/hash_serializer_spec.rb:31:in `block (5 levels) in <top (required)>'

  3)
  'LightMongo::Document::Serialization::HashSerializer.serialize_object(object_to_serialize, current_depth) when a non-primitive LightMongo::Document object when below the top level exports the object' FAILED
  expected: {"_class_name"=>"TestClass", "_id"=>#<Spec::Mocks::Mock:0x17f04b8 @name=:id>},
       got: {"_class_name"=>"#<Class:0x00000002feccc8>::TestClass", "_id"=>#<Spec::Mocks::Mock:0x17f04b8 @name=:id>} (using ==)
  /tmp/light_mongo/spec/document/serialization/hash_serializer_spec.rb:53:in `block (6 levels) in <top (required)>'

~

Owner

elliotcm commented Mar 19, 2010

Error 2 is some cross-chatter between spec files I haven't been able to pin down. If you run that file on its own it should pass.

For the other two, looks like Ruby1.9 handles instance.class.name differently. Interesting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment