diff options
author | Go MAEDA <maeda@farend.jp> | 2023-01-11 13:29:11 +0000 |
---|---|---|
committer | Go MAEDA <maeda@farend.jp> | 2023-01-11 13:29:11 +0000 |
commit | 1d3a76580f3eb732da45b99220cc8d64d277c535 (patch) | |
tree | 4698a777c447979710ab164d76934d8551e2e2e1 /test/integration/api_test | |
parent | 70ef2a3db14e9ea2588ddd206664a225d90396d4 (diff) | |
download | redmine-1d3a76580f3eb732da45b99220cc8d64d277c535.tar.gz redmine-1d3a76580f3eb732da45b99220cc8d64d277c535.zip |
Fix RuboCop offense Performance/FixedSize (#38146).
git-svn-id: https://svn.redmine.org/redmine/trunk@22030 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/integration/api_test')
-rw-r--r-- | test/integration/api_test/issues_test.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/integration/api_test/issues_test.rb b/test/integration/api_test/issues_test.rb index 132b6f815..425343c23 100644 --- a/test/integration/api_test/issues_test.rb +++ b/test/integration/api_test/issues_test.rb @@ -969,7 +969,8 @@ class Redmine::ApiTest::IssuesTest < Redmine::ApiTest::Base end def test_create_issue_with_uploaded_file - token = xml_upload('test_create_with_upload', credentials('jsmith')) + file_content = 'test_create_with_upload' + token = xml_upload(file_content, credentials('jsmith')) attachment = Attachment.find_by_token(token) # create the issue with the upload's token @@ -991,7 +992,7 @@ class Redmine::ApiTest::IssuesTest < Redmine::ApiTest::Base attachment.reload assert_equal 'test.txt', attachment.filename assert_equal 'text/plain', attachment.content_type - assert_equal 'test_create_with_upload'.size, attachment.filesize + assert_equal file_content.size, attachment.filesize assert_equal 2, attachment.author_id # get the issue with its attachments |