public
Rubygem
Description: DataMapper - Core
Homepage: http://datamapper.org
Clone URL: git://github.com/sam/dm-core.git
Fixed test typos for default association values
rughetto (author)
Wed May 21 00:07:07 -0700 2008
commit  6899fdcd2c4d81208d9567ffe800e01cddc6d93f
tree    e7486524a47a8dcd3ceff75c47b5f05521cf01ab
parent  b878af5b7366b95e681243b8e301ca86dd02f62d
...
8
9
10
11
 
12
13
14
...
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
...
8
9
10
 
11
12
13
14
...
451
452
453
 
454
455
456
 
457
458
459
 
460
461
462
0
@@ -8,7 +8,7 @@ if HAS_SQLITE3
0
     property :name, String
0
     repository(:sqlite3) do
0
       one_to_many :yards
0
- one_to_many :fussy_yards, {:rating.gte => 3, :type => "particular"}
0
+ one_to_many :fussy_yards, :class_name => "Yard", :rating.gte => 3, :type => "particular"
0
     end
0
   end
0
 
0
@@ -451,15 +451,12 @@ if HAS_SQLITE3
0
             engine.fussy_yards << Yard.new(:name => "yard 1", :rating => 4 )
0
             engine.save
0
             Yard.first(:name => "yard 1").type.should == "particular"
0
- engine.fussy_good_yards.size.should ==1
0
           # it should not add default values if the condition's property already has a value
0
             engine.fussy_yards << Yard.new(:name => "yard 2", :rating => 4, :type => "not particular")
0
             Yard.first(:name => "yard 2").type.should == "not particular"
0
- engine.fussy_good_yards.size.should ==1
0
           # it should ignore non :eql conditions
0
             engine.fussy_yards << Yard.new(:name => "yard 3")
0
             Yard.first(:name => "yard 3").type.should == "particular"
0
- engine.fussy_good_yards.size.should ==1
0
         end
0
       end
0
       

Comments

    No one has commented yet.