Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

should_respond_with_content_type does not test against the HTTP header #97

Closed
jarl-dk opened this Issue May 19, 2010 · 4 comments

Comments

Projects
None yet
3 participants

jarl-dk commented May 19, 2010

Hi I am converting some existing tests to shoulda.

My current test looks like this:
assert_equal Mime::KML.to_s + '; charset=utf-8', @response.header["Content-Type"]

I replace this with
should_respond_with_content_type Mime::KML.to_s + '; charset=utf-8'

but that fails because shoulda tests against @controller.response.content_type and not @controller.response.header["Content-Type"]

Contributor

gabebw commented Mar 18, 2012

@jarl-dk: Is this still an issue with the latest shoulda?

jarl-dk commented Mar 28, 2012

Yes...

Contributor

gabebw commented Mar 28, 2012

Thanks for checking. I know it's been a while since you filed this issue.

Owner

mike-burns commented Jul 9, 2012

I've opened an issue on shoulda-matchers so we can track this more closely to the source: thoughtbot/shoulda-matchers#128

@mike-burns mike-burns closed this Jul 9, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment