corrected the naming of #accept, before #media_types
This commit is contained in:
parent
f7c2a53f00
commit
90445fb473
|
@ -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
|
||||
|
||||
|
|
|
@ -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
|
Loading…
Reference in New Issue