diff options
author | Arthur Nogueira Neves <github@arthurnn.com> | 2015-05-20 22:41:19 +0200 |
---|---|---|
committer | Arthur Nogueira Neves <github@arthurnn.com> | 2015-05-20 22:41:19 +0200 |
commit | c36423984dbc57a861a076e36c4da9d061e9a1ad (patch) | |
tree | 275b9d70b9e0bbfd5e71a35aa37474c2ea460c4d /actionpack/test | |
parent | 6577d049efc4885391cce7f03f6c62194659b399 (diff) | |
parent | 76d8a2a63821eb2afcad7e6adfd126c5448bb6c9 (diff) | |
download | rails-c36423984dbc57a861a076e36c4da9d061e9a1ad.tar.gz rails-c36423984dbc57a861a076e36c4da9d061e9a1ad.tar.bz2 rails-c36423984dbc57a861a076e36c4da9d061e9a1ad.zip |
Merge pull request #17788 from sivagollapalli/master
Issue#17703 Test case for tempfile attribute
Diffstat (limited to 'actionpack/test')
-rw-r--r-- | actionpack/test/controller/test_case_test.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/actionpack/test/controller/test_case_test.rb b/actionpack/test/controller/test_case_test.rb index e348749f78..a1afdc32c7 100644 --- a/actionpack/test/controller/test_case_test.rb +++ b/actionpack/test/controller/test_case_test.rb @@ -908,6 +908,11 @@ XML assert_equal File.open(path, READ_PLAIN).read, plain_file_upload.read end + def test_fixture_file_upload_should_be_able_access_to_tempfile + file = fixture_file_upload(FILES_DIR + "/mona_lisa.jpg", "image/jpg") + assert file.respond_to?(:tempfile), "expected tempfile should respond on fixture file object, got nothing" + end + def test_fixture_file_upload post :test_file_upload, params: { |