Fix RuboCop offense Layout/EmptyLinesAroundClassBody, one of the offenses enabled in rubocop-rails-omakase (#39887).

git-svn-id: https://svn.redmine.org/redmine/trunk@22949 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Go MAEDA
2024-08-12 07:42:12 +00:00
parent 0c28b0974a
commit de76bb3a4a
17 changed files with 0 additions and 38 deletions

View File

@@ -44,28 +44,6 @@ Layout/EmptyLinesAroundAttributeAccessor:
- 'lib/redmine/sudo_mode.rb'
- 'test/unit/lib/redmine/safe_attributes_test.rb'
# This cop supports safe autocorrection (--autocorrect).
# Configuration parameters: EnforcedStyle.
# SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
Layout/EmptyLinesAroundClassBody:
Exclude:
- 'db/migrate/001_setup.rb'
- 'db/migrate/007_create_journals.rb'
- 'db/migrate/20110223180953_salt_user_passwords.rb'
- 'db/migrate/20131215104612_store_relation_type_in_journal_details.rb'
- 'db/migrate/20180923082945_change_sqlite_booleans_to_0_and_1.rb'
- 'lib/redmine/notifiable.rb'
- 'lib/redmine/scm/adapters/cvs_adapter.rb'
- 'lib/redmine/scm/adapters/filesystem_adapter.rb'
- 'lib/redmine/wiki_formatting/html_parser.rb'
- 'lib/redmine/wiki_formatting/markdown/html_parser.rb'
- 'lib/redmine/wiki_formatting/textile/html_parser.rb'
- 'test/integration/api_test/api_routing_test.rb'
- 'test/integration/lib/redmine/themes_test.rb'
- 'test/integration/routing/activities_test.rb'
- 'test/integration/routing/repositories_test.rb'
- 'test/unit/lib/redmine/field_format/link_format_test.rb'
# This cop supports safe autocorrection (--autocorrect).
Layout/EmptyLinesAroundExceptionHandlingKeywords:
Exclude:

View File

@@ -16,7 +16,6 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
class Setup < ActiveRecord::Migration[4.2]
class User < ActiveRecord::Base
end

View File

@@ -1,5 +1,4 @@
class CreateJournals < ActiveRecord::Migration[4.2]
# model removed, but needed for data migration
class IssueHistory < ActiveRecord::Base; belongs_to :issue; end
# model removed

View File

@@ -1,5 +1,4 @@
class SaltUserPasswords < ActiveRecord::Migration[4.2]
def self.up
say_with_time "Salting user passwords, this may take some time..." do
User.salt_unsalted_passwords!

View File

@@ -1,5 +1,4 @@
class StoreRelationTypeInJournalDetails < ActiveRecord::Migration[4.2]
MAPPING = {
"label_relates_to" => "relates",
"label_duplicates" => "duplicates",

View File

@@ -1,5 +1,4 @@
class ChangeSqliteBooleansTo0And1 < ActiveRecord::Migration[5.2]
COLUMNS = {
AuthSource => ['onthefly_register', 'tls'],
CustomFieldEnumeration => ['active'],

View File

@@ -19,7 +19,6 @@
module Redmine
class Notifiable < Struct.new(:name, :parent)
def to_s
name
end

View File

@@ -23,7 +23,6 @@ module Redmine
module Scm
module Adapters
class CvsAdapter < AbstractAdapter
# CVS executable name
CVS_BIN = Redmine::Configuration['scm_cvs_command'] || "cvs"

View File

@@ -26,7 +26,6 @@ module Redmine
module Scm
module Adapters
class FilesystemAdapter < AbstractAdapter
class << self
def client_available
true

View File

@@ -22,7 +22,6 @@ require 'loofah/helpers'
module Redmine
module WikiFormatting
class HtmlParser
class_attribute :tags
self.tags = {
'br' => {:post => "\n"},

View File

@@ -21,7 +21,6 @@ module Redmine
module WikiFormatting
module Markdown
class HtmlParser < Redmine::WikiFormatting::HtmlParser
self.tags = tags.merge(
'b' => {:pre => '**', :post => '**'},
'strong' => {:pre => '**', :post => '**'},

View File

@@ -21,7 +21,6 @@ module Redmine
module WikiFormatting
module Textile
class HtmlParser < Redmine::WikiFormatting::HtmlParser
self.tags = tags.merge(
'b' => {:pre => '*', :post => '*'},
'strong' => {:pre => '*', :post => '*'},

View File

@@ -20,7 +20,6 @@
require_relative '../../test_helper'
class Redmine::ApiTest::ApiRoutingTest < Redmine::ApiTest::Routing
def test_attachments
should_route 'GET /attachments/1' => 'attachments#show', :id => '1'
should_route 'PATCH /attachments/1' => 'attachments#update', :id => '1'

View File

@@ -20,7 +20,6 @@
require_relative '../../../test_helper'
class ThemesTest < Redmine::IntegrationTest
def setup
Redmine::Themes.rescan
@theme = Redmine::Themes.theme('classic')

View File

@@ -20,7 +20,6 @@
require_relative '../../test_helper'
class RoutingActivitiesTest < Redmine::RoutingTest
def test_activity
should_route 'GET /activity' => 'activities#index'
should_route 'GET /activity.atom' => 'activities#index', :format => 'atom'

View File

@@ -20,7 +20,6 @@
require_relative '../../test_helper'
class RoutingRepositoriesTest < Redmine::RoutingTest
def setup
@paths = ['path/to/index.html',
'path/to/file.c', 'path/to/file.yaml', 'path/to/file.txt',

View File

@@ -21,7 +21,6 @@ require_relative '../../../../test_helper'
require 'redmine/field_format'
class Redmine::LinkFieldFormatTest < ActionView::TestCase
def setup
User.current = nil
end