Use RABL to build JSON responses given by API

This commit is contained in:
Thibault Jouan
2012-03-11 23:25:57 +00:00
parent 8681999d4c
commit 196ea16a94
7 changed files with 34 additions and 1 deletions

View File

@@ -20,6 +20,10 @@ describe Api::V0::PlaylistsController do
do_get.should have(2).items
end
it 'lists playlists with their id' do
do_get.each { |t| t.keys.should include 'id' }
end
it 'lists playlists with their name' do
do_get.each { |t| t.keys.should include 'name' }
end