Use around hook to restore context in InstanceHelper spec (#3429)

master
Akihiko Odaki 7 years ago committed by Matt Jankowski
parent 67bc58dd60
commit dfc43a6d3d
  1. 6
      spec/helpers/instance_helper_spec.rb

@ -4,6 +4,12 @@ require 'rails_helper'
describe InstanceHelper do
describe 'site_title' do
around do |example|
site_title = Setting.site_title
example.run
Setting.site_title = site_title
end
it 'Uses the Setting.site_title value when it exists' do
Setting.site_title = 'New site title'

Loading…
Cancel
Save