Forum: Ruby on Rails testing with specific request env

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
75da740d43c5780539214f24ce1148a6?d=identicon&s=25 Jean Helou (Guest)
on 2007-01-20 11:16
(Received via mailing list)

I can't seem to be able to add specific headers to a
ActionController::TestRequest. The controller never sees them.

I have recreated the problem in the most simple form I could

line 28 should pass right ?

this works fine using the normal CGIRequest object ... :/ but makes it
hard to test controllers whose actions depend on headers which are not
used by rails (such as HTTP_ACCEPT_LANGUAGE)

have I missed something ?


I join a tgz with a complete and fresh rails 1.2.1 and all the
necessary files to run rake test and see it fail.
This topic is locked and can not be replied to.