Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.68 KB | None | 0 0
  1. describe 'articles' do
  2.   it 'should route to articles index' do
  3.     expect(get '/articles').to route_to('articles#index')
  4.   end
  5.  
  6.   it 'should route to articles show' do
  7.     expect(get '/articles/1').to route_to('articles#show', id: '1')
  8.   end
  9.  
  10.   it 'should route to articles create' do
  11.     expect(post '/articles').to route_to('articles#create')
  12.   end
  13.  
  14.   it 'should route to articles update' do
  15.     expect(put '/articles/1').to route_to('articles#update', id: '1')
  16.     expect(patch '/articles/1').to route_to('articles#update', id: '1')
  17.   end
  18.  
  19.   it 'should route to articles destroy' do
  20.     expect(delete '/articles/1').to route_to('articles#destroy', id: '1')
  21.   end
  22. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement