diff options
author | Arthur Nogueira Neves <github@arthurnn.com> | 2015-10-12 14:26:11 -0400 |
---|---|---|
committer | Arthur Nogueira Neves <github@arthurnn.com> | 2015-10-12 14:26:11 -0400 |
commit | 96747036715a658ab21e921919d45d6149949d55 (patch) | |
tree | 7a6cee887f29829273bd228cbe310030a4fd32d0 /railties | |
parent | 9f4cefd28ff2d126a5b314e80cf609709226d5ad (diff) | |
parent | f0a3af209f021774f0f2360d8843a3f630312431 (diff) | |
download | rails-96747036715a658ab21e921919d45d6149949d55.tar.gz rails-96747036715a658ab21e921919d45d6149949d55.tar.bz2 rails-96747036715a658ab21e921919d45d6149949d55.zip |
Merge pull request #17388 from akampjes/master
ActionMailer https on URL with force_ssl = true
Diffstat (limited to 'railties')
-rw-r--r-- | railties/test/application/initializers/frameworks_test.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/railties/test/application/initializers/frameworks_test.rb b/railties/test/application/initializers/frameworks_test.rb index 6e3707cc27..13f3250f5b 100644 --- a/railties/test/application/initializers/frameworks_test.rb +++ b/railties/test/application/initializers/frameworks_test.rb @@ -49,6 +49,17 @@ module ApplicationTests assert_equal "test.rails", ActionMailer::Base.default_url_options[:host] end + test "Default to HTTPS for ActionMailer URLs when force_ssl is on" do + app_file "config/environments/development.rb", <<-RUBY + Rails.application.configure do + config.force_ssl = true + end + RUBY + + require "#{app_path}/config/environment" + assert_equal "https", ActionMailer::Base.default_url_options[:protocol] + end + test "includes url helpers as action methods" do app_file "config/routes.rb", <<-RUBY Rails.application.routes.draw do |