Sha256: a031f103467c8d5742c0711a56b9dd3b013d5f2bb05073d814360b8265ab34d6
Contents?: true
Size: 597 Bytes
Versions: 5
Compression:
Stored size: 597 Bytes
Contents
describe 'Settings requests', type: :request do describe 'layout' do it 'use default application layout' do get '/settings' expect(response).to be_successful expect(response).to render_template(layout: 'application') end it 'use custom layout' do change_layout('admin') get '/settings' expect(response).to be_successful expect(response).to render_template(layout: 'admin') change_layout('application') end end begin 'Helper methods' def change_layout(layout_name) ENV['LAYOUT_NAME'] = layout_name end end end
Version data entries
5 entries across 5 versions & 1 rubygems