aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2014-12-08 15:10:47 -0200
committerRafael Mendonça França <rafaelmfranca@gmail.com>2014-12-08 15:10:47 -0200
commitc8284c8025dd63c30bdb9c905ef725a1a13160a8 (patch)
tree7e8b6ec5210dba7f95048eee475096f3b85584c9 /railties/test
parent3d06f77ee6e95b467a66bc8c60ad19058ab3e6ba (diff)
parentccc3ddb7762bae0df7e2f8d643b19b6a4769d5be (diff)
downloadrails-c8284c8025dd63c30bdb9c905ef725a1a13160a8.tar.gz
rails-c8284c8025dd63c30bdb9c905ef725a1a13160a8.tar.bz2
rails-c8284c8025dd63c30bdb9c905ef725a1a13160a8.zip
Merge pull request #17896 from GBH/globbing_route_mailer_preview
fixing mailer previews for apps with globbing route
Diffstat (limited to 'railties/test')
-rw-r--r--railties/test/application/mailer_previews_test.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/railties/test/application/mailer_previews_test.rb b/railties/test/application/mailer_previews_test.rb
index 55e917c3ec..9e4f858539 100644
--- a/railties/test/application/mailer_previews_test.rb
+++ b/railties/test/application/mailer_previews_test.rb
@@ -40,6 +40,17 @@ module ApplicationTests
assert_equal 404, last_response.status
end
+ test "/rails/mailers is accessible with globbing route present" do
+ app_file "config/routes.rb", <<-RUBY
+ Rails.application.routes.draw do
+ get '*foo', to: 'foo#index'
+ end
+ RUBY
+ app("development")
+ get "/rails/mailers"
+ assert_equal 200, last_response.status
+ end
+
test "mailer previews are loaded from the default preview_path" do
mailer 'notifier', <<-RUBY
class Notifier < ActionMailer::Base