Permalink
Browse files

Correctly define _id as bson ordered hash.

The reason the modifier tests were failing is because in #attributes, _id was being converted to a hash with indifferent access instead of staying a bson ordered hash.
  • Loading branch information...
1 parent 942003c commit 197c2f649f574a0932773e73cca2c5cb1235af3f @jnunemaker jnunemaker committed Oct 22, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 test/functional/test_modifiers.rb
@@ -6,7 +6,7 @@ class ModifierTest < Test::Unit::TestCase
def setup
compound_key = BSON::OrderedHash['n', 42, 'i', BSON::ObjectId.new]
@page_class_with_compound_key = Doc do
- key :_id, :default => lambda { compound_key }
+ key :_id, BSON::OrderedHash, :default => lambda { compound_key }
key :title, String
key :day_count, Integer, :default => 0
key :week_count, Integer, :default => 0

0 comments on commit 197c2f6

Please sign in to comment.