Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9eeb24c
commit 1e50fae
Showing
1 changed file
with
25 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
require 'abstract_unit' | ||
|
||
module ActionDispatch | ||
class UploadedFileTest < ActiveSupport::TestCase | ||
def test_original_filename | ||
uf = Http::UploadedFile.new(:filename => 'foo') | ||
assert_equal 'foo', uf.original_filename | ||
end | ||
|
||
def test_content_type | ||
uf = Http::UploadedFile.new(:type => 'foo') | ||
assert_equal 'foo', uf.content_type | ||
end | ||
|
||
def test_headers | ||
uf = Http::UploadedFile.new(:head => 'foo') | ||
assert_equal 'foo', uf.headers | ||
end | ||
|
||
def test_tempfile | ||
uf = Http::UploadedFile.new(:tempfile => 'foo') | ||
assert_equal 'foo', uf.tempfile | ||
end | ||
end | ||
end |