diff options
Diffstat (limited to 'spec/unit/request/accept')
-rw-r--r-- | spec/unit/request/accept/preferred_spec.rb | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/spec/unit/request/accept/preferred_spec.rb b/spec/unit/request/accept/preferred_spec.rb index 5d11799..03a7267 100644 --- a/spec/unit/request/accept/preferred_spec.rb +++ b/spec/unit/request/accept/preferred_spec.rb @@ -13,11 +13,6 @@ describe Zero::Request::Accept, '#preferred' do let(:lower_accept) { [lower_quality, default].join(',') } context 'without mapping' do - before :each do - # reset the mapping to nothing - Zero::Request::Accept.map = {} - end - it { subject.new(html).preferred.should == html } it { subject.new(json).preferred.should == json } it { subject.new(simple_accept).preferred.should == html } @@ -31,6 +26,10 @@ describe Zero::Request::Accept, '#preferred' do Zero::Request::Accept.map = {'text/html' => 'html'} end + after :all do + Zero::Request::Accept.map = {} + end + it { subject.new(html).preferred.should == 'html' } end end |