Sha256: 845dc01726e5e453e9526f4bb66dfedf2db0e95ef2ddeadfb16b31d46bd7aae3
Contents?: true
Size: 1.09 KB
Versions: 2
Compression:
Stored size: 1.09 KB
Contents
require 'spec_helper' describe Museum::CasesController do include_context 'loupe support' include_context 'case support' describe 'GET index' do before(:each) { get :index, { use_route: 'museum' } } it { should respond_with(:success) } it { should render_template(:index) } end describe 'GET show' do context 'with an invalid gem name' do before(:each) { get :show, { use_route: 'museum', id: 'bad' } } it { should respond_with(:not_found) } end context 'with a valid gem name' do before(:each) { get :show, { use_route: 'museum', id: 'bootswitch' } } it { should respond_with(:success) } it { should render_template(:show) } end end describe 'GET refresh' do context 'with an invalid gem name' do before(:each) { get :refresh, { use_route: 'museum', id: 'bad' } } it { should respond_with(:not_found) } end context 'with a valid gem name' do before(:each) { get :refresh, { use_route: 'museum', id: 'bootswitch' } } it { should respond_with(:redirect) } it { should set_the_flash } end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
museum-0.3.0 | spec/controllers/cases_controller_spec.rb |
museum-0.2.2 | spec/controllers/cases_controller_spec.rb |