diff options
author | John Hawthorn <john@hawthorn.email> | 2019-03-18 10:13:35 -0700 |
---|---|---|
committer | John Hawthorn <john@hawthorn.email> | 2019-03-18 11:12:22 -0700 |
commit | ffc842a09927986819cf7a66ae6a15f97bfeed76 (patch) | |
tree | 17522f7c287d5fd4f8d2a1a8a2e1cc9dd926af19 /actionview/test | |
parent | c555e28a4cf3690a95b5ed108d174f39cedd19b1 (diff) | |
download | rails-ffc842a09927986819cf7a66ae6a15f97bfeed76.tar.gz rails-ffc842a09927986819cf7a66ae6a15f97bfeed76.tar.bz2 rails-ffc842a09927986819cf7a66ae6a15f97bfeed76.zip |
Make uniq in LookupContext#formats=
Having a format listed twice had no effect. This is mostly helpful to
avoid an extra format when assigning [:html, "*/*"]
Diffstat (limited to 'actionview/test')
-rw-r--r-- | actionview/test/template/lookup_context_test.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionview/test/template/lookup_context_test.rb b/actionview/test/template/lookup_context_test.rb index 8b61302c32..ce5b4c4f66 100644 --- a/actionview/test/template/lookup_context_test.rb +++ b/actionview/test/template/lookup_context_test.rb @@ -72,7 +72,7 @@ class LookupContextTest < ActiveSupport::TestCase test "handles explicitly defined */* formats fallback to :js" do @lookup_context.formats = [:js, Mime::ALL] - assert_equal [:js, *Mime::SET.symbols], @lookup_context.formats + assert_equal [:js, *Mime::SET.symbols].uniq, @lookup_context.formats end test "adds :html fallback to :js formats" do |