mirror of
https://github.com/redmine/redmine.git
synced 2025-11-15 09:46:02 +01:00
code cleanup: rubocop: fix Layout/IndentHeredoc in test/integration/api_test/files_test.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18650 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -270,7 +270,6 @@ Layout/IndentFirstHashElement:
|
||||
Layout/IndentHeredoc:
|
||||
Exclude:
|
||||
- 'test/helpers/application_helper_test.rb'
|
||||
- 'test/integration/api_test/files_test.rb'
|
||||
- 'test/integration/lib/redmine/hook_test.rb'
|
||||
- 'test/unit/lib/redmine/syntax_highlighting/rouge_test.rb'
|
||||
- 'test/unit/lib/redmine/unified_diff_test.rb'
|
||||
|
||||
@@ -41,7 +41,7 @@ class Redmine::ApiTest::FilesTest < Redmine::ApiTest::Base
|
||||
:params => 'File content',
|
||||
:headers => {"CONTENT_TYPE" => 'application/octet-stream'}.merge(credentials('jsmith'))
|
||||
token = Attachment.last.token
|
||||
payload = <<-JSON
|
||||
payload = <<~JSON
|
||||
{ "file": {
|
||||
"token": "#{token}"
|
||||
}
|
||||
@@ -61,7 +61,7 @@ class Redmine::ApiTest::FilesTest < Redmine::ApiTest::Base
|
||||
:params => 'File content',
|
||||
:headers => {"CONTENT_TYPE" => 'application/octet-stream'}.merge(credentials('jsmith'))
|
||||
token = Attachment.last.token
|
||||
payload = <<-XML
|
||||
payload = <<~XML
|
||||
<file>
|
||||
<token>#{token}</token>
|
||||
</file>
|
||||
@@ -75,7 +75,7 @@ class Redmine::ApiTest::FilesTest < Redmine::ApiTest::Base
|
||||
end
|
||||
|
||||
test "POST /projects/:project_id/files.json should refuse requests without the :token parameter" do
|
||||
payload = <<-JSON
|
||||
payload = <<~JSON
|
||||
{ "file": {
|
||||
"filename": "project_file.zip",
|
||||
}
|
||||
@@ -93,7 +93,7 @@ class Redmine::ApiTest::FilesTest < Redmine::ApiTest::Base
|
||||
:params => 'File content',
|
||||
:headers => {"CONTENT_TYPE" => 'application/octet-stream'}.merge(credentials('jsmith'))
|
||||
token = Attachment.last.token
|
||||
payload = <<-JSON
|
||||
payload = <<~JSON
|
||||
{ "file": {
|
||||
"filename": "New filename",
|
||||
"description": "New description",
|
||||
@@ -117,7 +117,7 @@ class Redmine::ApiTest::FilesTest < Redmine::ApiTest::Base
|
||||
:params => 'File content',
|
||||
:headers => {"CONTENT_TYPE" => 'application/octet-stream'}.merge(credentials('jsmith'))
|
||||
token = Attachment.last.token
|
||||
payload = <<-JSON
|
||||
payload = <<~JSON
|
||||
{ "file": {
|
||||
"version_id": 3,
|
||||
"filename": "New filename",
|
||||
|
||||
Reference in New Issue
Block a user