Skip to content

Commit

Permalink
Fix Layout/HashAlignment cop
Browse files Browse the repository at this point in the history
  • Loading branch information
archanaserver committed Jun 10, 2024
1 parent 843dd12 commit f837f5a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 13 deletions.
7 changes: 2 additions & 5 deletions .rubocop_todo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ Layout/ExtraSpacing:
Layout/FirstArrayElementIndentation:
EnforcedStyle: consistent

# Offense count: 25
# This cop supports safe autocorrection (--autocorrect).
# Offense count: 17
# Cop supports --auto-correct.
# Configuration parameters: AllowMultipleStyles, EnforcedHashRocketStyle, EnforcedColonStyle, EnforcedLastArgumentHashStyle.
# SupportedHashRocketStyles: key, separator, table
# SupportedColonStyles: key, separator, table
Expand All @@ -67,9 +67,6 @@ Layout/HashAlignment:
Exclude:
- 'lib/hammer_cli_katello/id_resolver.rb'
- 'test/functional/content_export/complete/version_test.rb'
- 'test/functional/content_view/component/add_test.rb'
- 'test/functional/content_view/component/remove_test.rb'
- 'test/functional/content_view/component/update_test.rb'

# Offense count: 3
# This cop supports safe autocorrection (--autocorrect).
Expand Down
2 changes: 1 addition & 1 deletion test/functional/content_view/component/add_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module HammerCLIKatello
@composite = ::OpenStruct.new(:id => 2, :name => "composite")
@component_version = ::OpenStruct.new(:id => 666, :version => "1.0")
@component = ::OpenStruct.new(:id => 6, :name => "component",
:content_view_version => @component_version)
:content_view_version => @component_version)
@organization = ::OpenStruct.new(:id => 1, :name => "great", :label => "label")
end

Expand Down
6 changes: 3 additions & 3 deletions test/functional/content_view/component/remove_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ module HammerCLIKatello
@component2 = ::OpenStruct.new(:id => 7, :name => "component2")

@content_view_component = ::OpenStruct.new(:id => 1444,
:content_view => @component)
:content_view => @component)

@content_view_component2 = ::OpenStruct.new(:id => 1445,
:content_view => @component2)
:content_view => @component2)

@composite = ::OpenStruct.new(:id => 2, :name => "composite",
:content_view_components => [@content_view_component])
:content_view_components => [@content_view_component])
@organization = ::OpenStruct.new(:id => 1, :name => "great", :label => "label")
@content_view_components = [@content_view_component, @content_view_component2]
end
Expand Down
8 changes: 4 additions & 4 deletions test/functional/content_view/component/update_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ module HammerCLIKatello
@cmd = %w(content-view component update)
@component_version = ::OpenStruct.new(:id => 666, :version => "1.0")
@component = ::OpenStruct.new(:id => 6, :name => "component",
:content_view_version => @component_version)
:content_view_version => @component_version)
@content_view_component = ::OpenStruct.new(:id => 1444,
:content_view => @component,
:content_view_version => @component_version)
:content_view => @component,
:content_view_version => @component_version)

@composite = ::OpenStruct.new(:id => 2, :name => "composite",
:content_view_components => [@content_view_component])
:content_view_components => [@content_view_component])
@organization = ::OpenStruct.new(:id => 1, :name => "great", :label => "label")
end

Expand Down

0 comments on commit f837f5a

Please sign in to comment.