summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAustin Ziegler <austin@zieglers.ca>2014-05-20 21:29:37 -0400
committerAustin Ziegler <austin@zieglers.ca>2014-05-20 21:29:37 -0400
commit07362bbf9ceb184e4c89c37831934423eafb1011 (patch)
treec166e2f94fa4a21dbea6fa3bbef6f1c031c69433 /test
parent96413d7f939bba45b1d98f5216040d37c987fead (diff)
downloadmime-types-07362bbf9ceb184e4c89c37831934423eafb1011.tar.gz
Fix a bug with MIME::Types#type_for.
* MIME::Types.type_for('unknown') should return [], not [nil].
Diffstat (limited to 'test')
-rw-r--r--test/test_mime_types.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/test_mime_types.rb b/test/test_mime_types.rb
index 3ffe9d5..fe7ea32 100644
--- a/test/test_mime_types.rb
+++ b/test/test_mime_types.rb
@@ -72,6 +72,7 @@ class TestMIMETypes < Minitest::Test
assert_equal(%w(image/jpeg text/plain),
MIME::Types.type_for(%w(foo.txt foo.jpeg)))
assert_equal(@mime_types.of('gif', true), @mime_types['image/gif'])
+ assert_empty(MIME::Types.type_for('coverallsjson'))
assert_deprecated("MIME::Types#type_for", "using the platform parameter") do
assert_empty(MIME::Types.type_for('jpeg', true))
end