0
0
Fork 0

corrected the naming of #accept, before #media_types

This commit is contained in:
Gibheer 2012-11-16 14:17:44 +01:00
parent f7c2a53f00
commit 90445fb473
2 changed files with 8 additions and 1 deletions

View File

@ -54,7 +54,7 @@ module Zero
# get the media types
# @return [Accept] on Accept object managing all types and their order
def media_types
def accept
@accept ||= Request::Accept.new(@env)
end

View File

@ -0,0 +1,7 @@
require 'spec_helper'
describe Zero::Request, '#accept' do
subject { Zero::Request.new(env) }
let(:env) { EnvGenerator.get('/foo') }
its(:accept) { should be_an_instance_of(Zero::Request::Accept) }
end