mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
L #-: linting for rubocop 0.92.0
This commit is contained in:
parent
4656ef202e
commit
c61454f444
@ -573,6 +573,9 @@ Layout/SpaceAroundMethodCallOperator:
|
||||
Layout/EmptyLinesAroundAttributeAccessor:
|
||||
Enabled: true
|
||||
|
||||
Layout/BeginEndAlignment:
|
||||
Enabled: true
|
||||
|
||||
#######
|
||||
# STYLE
|
||||
#######
|
||||
@ -719,6 +722,33 @@ Style/RedundantRegexpCharacterClass:
|
||||
Style/RedundantRegexpEscape:
|
||||
Enabled: False
|
||||
|
||||
Style/CombinableLoops:
|
||||
Enabled: false
|
||||
|
||||
Style/ExplicitBlockArgument:
|
||||
Enabled: true
|
||||
|
||||
Style/GlobalStdStream:
|
||||
Enabled: false
|
||||
|
||||
Style/KeywordParametersOrder:
|
||||
Enabled: true
|
||||
|
||||
Style/OptionalBooleanParameter:
|
||||
Enabled: false
|
||||
|
||||
Style/RedundantSelfAssignment:
|
||||
Enabled: true
|
||||
|
||||
Style/SingleArgumentDig:
|
||||
Enabled: true
|
||||
|
||||
Style/SoleNestedConditional:
|
||||
Enabled: false
|
||||
|
||||
Style/StringConcatenation:
|
||||
Enabled: false
|
||||
|
||||
######
|
||||
# LINT
|
||||
######
|
||||
@ -777,6 +807,53 @@ Lint/DuplicateElsifCondition:
|
||||
Lint/MixedRegexpCaptureTypes:
|
||||
Enabled: True
|
||||
|
||||
Lint/BinaryOperatorWithIdenticalOperands:
|
||||
Enabled: true
|
||||
|
||||
Lint/ConstantDefinitionInBlock:
|
||||
Enabled: false
|
||||
|
||||
Lint/DuplicateRequire:
|
||||
Enabled: true
|
||||
|
||||
Lint/DuplicateRescueException:
|
||||
Enabled: true
|
||||
|
||||
Lint/EmptyConditionalBody:
|
||||
Enabled: true
|
||||
|
||||
Lint/EmptyFile:
|
||||
Enabled: true
|
||||
|
||||
Lint/FloatComparison:
|
||||
Enabled: false
|
||||
|
||||
Lint/IdentityComparison:
|
||||
Enabled: true
|
||||
|
||||
Lint/MissingSuper:
|
||||
Enabled: true
|
||||
|
||||
Lint/OutOfRangeRegexpRef:
|
||||
Enabled: true
|
||||
|
||||
Lint/SelfAssignment:
|
||||
Enabled: true
|
||||
|
||||
Lint/TopLevelReturnWithArgument:
|
||||
Enabled: true
|
||||
Lint/TrailingCommaInAttributeDeclaration:
|
||||
Enabled: true
|
||||
|
||||
Lint/UnreachableLoop:
|
||||
Enabled: true
|
||||
|
||||
Lint/UselessMethodDefinition:
|
||||
Enabled: true
|
||||
|
||||
Lint/UselessTimes:
|
||||
Enabled: true
|
||||
|
||||
#########
|
||||
# METRICS
|
||||
########
|
||||
|
@ -532,7 +532,7 @@ module CLIHelper
|
||||
# @param data [Array] Array with data to show
|
||||
# @param del [Char] CSV delimiter
|
||||
def print_csv_data(data, del)
|
||||
del ? del = del : del = ','
|
||||
del ||= ','
|
||||
|
||||
data.each do |l|
|
||||
result = []
|
||||
|
@ -32,6 +32,7 @@ class OneProvisionLoopException < RuntimeError
|
||||
attr_reader :text
|
||||
|
||||
def initialize(text = nil)
|
||||
super
|
||||
@text = text
|
||||
end
|
||||
|
||||
|
@ -39,6 +39,7 @@ class FirecrackerConfiguration < Hash
|
||||
FIRECRACKERRC = '../../etc/vmm/firecracker/firecrackerrc'
|
||||
|
||||
def initialize
|
||||
super
|
||||
replace(DEFAULT_CONFIGURATION)
|
||||
|
||||
begin
|
||||
|
@ -54,11 +54,6 @@ module NSXDriver
|
||||
# ATTRIBUTES
|
||||
attr_reader :one_section_name
|
||||
|
||||
# CONSTRUCTOR
|
||||
def initialize(nsx_client)
|
||||
super(nsx_client)
|
||||
end
|
||||
|
||||
def self.new_child(nsx_client)
|
||||
case nsx_client
|
||||
when NSXTClient
|
||||
|
@ -22,10 +22,6 @@ module NSXDriver
|
||||
|
||||
# CONSTRUCTOR
|
||||
|
||||
def initialize(nsx_client)
|
||||
super(nsx_client)
|
||||
end
|
||||
|
||||
def self.new_child(nsx_client, id = nil)
|
||||
case nsx_client.nsx_type.upcase
|
||||
when NSXConstants::NSXT
|
||||
|
@ -25,12 +25,6 @@ module NSXDriver
|
||||
attr_reader :display_name
|
||||
attr_reader :description
|
||||
|
||||
# CONSTRUCTOR
|
||||
|
||||
def initialize(nsx_client)
|
||||
super(nsx_client)
|
||||
end
|
||||
|
||||
def ls?; end
|
||||
|
||||
# Get logical switch's name
|
||||
|
@ -21,11 +21,6 @@ module NSXDriver
|
||||
# ATTRIBUTES
|
||||
attr_reader :tz_id
|
||||
|
||||
# CONSTRUCTOR
|
||||
def initialize(nsx_client)
|
||||
super(nsx_client)
|
||||
end
|
||||
|
||||
def self.new_child(nsx_client)
|
||||
case nsx_client.nsx_type.upcase
|
||||
when NSXConstants::NSXT
|
||||
|
@ -20,10 +20,6 @@ module VirtualMachineDevice
|
||||
|
||||
attr_reader :size
|
||||
|
||||
def initialize(id, one_res, vc_res)
|
||||
super(id, one_res, vc_res)
|
||||
end
|
||||
|
||||
# Create the OpenNebula disk representation
|
||||
# Allow us to create the class without vCenter representation
|
||||
# example: attached disks not synced with vCenter
|
||||
|
@ -18,10 +18,6 @@ module VirtualMachineDevice
|
||||
# Nic class
|
||||
class Nic < Device
|
||||
|
||||
def initialize(id, one_res, vc_res)
|
||||
super(id, one_res, vc_res)
|
||||
end
|
||||
|
||||
# Create the OpenNebula nic representation
|
||||
# Allow as to create the class without vCenter representation
|
||||
# example: attached nics not synced with vCenter
|
||||
|
@ -58,6 +58,7 @@ class VCenterConf < Hash
|
||||
}
|
||||
|
||||
def initialize
|
||||
super
|
||||
replace(DEFAULT_CONFIGURATION)
|
||||
begin
|
||||
vcenterrc_path = "#{VAR_LOCATION}/remotes/etc/vmm/vcenter/vcenterrc"
|
||||
|
Loading…
x
Reference in New Issue
Block a user