Fix polymorphic test

One assertion comment says look for association with dog but the code
still uses cat. This aligns the code to now look at the association of
the dog.
This commit is contained in:
James C. Scott 2016-01-06 10:34:42 -05:00
parent 2f7811c55f
commit 195d5993b3
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ func TestPolymorphic(t *testing.T) {
t.Errorf("Cat's toys count should be 1") t.Errorf("Cat's toys count should be 1")
} }
if DB.Model(&cat).Association("Toy").Count() != 1 { if DB.Model(&dog).Association("Toys").Count() != 2 {
t.Errorf("Dog's toys count should be 2") t.Errorf("Dog's toys count should be 2")
} }