add base object

This commit is contained in:
William Cheng
2015-05-16 03:51:21 +08:00
parent 0e0e265a2a
commit 8710fbfde7
13 changed files with 1033 additions and 156 deletions

View File

@@ -49,7 +49,10 @@ def prepare_pet
# remove the pet
PetApi.delete_pet(10002)
# recreate the pet
pet = Pet.new('id' => 10002, 'name' => "RUBY UNIT TESTING")
category = Category.new('id' => 20002, 'name' => 'category test')
tag = Tag.new('id' => 30002, 'name' => 'tag test')
pet = Pet.new('id' => 10002, 'name' => "RUBY UNIT TESTING", 'photo_urls' => 'photo url',
'category' => category, 'tags' => [tag], 'status' => 'pending')
PetApi.add_pet(:body => pet)
end