Fix a few method signature checks

This commit is contained in:
Gabriel Mazetto 2017-02-13 12:20:56 +01:00
parent 442735978c
commit a4460f420b
2 changed files with 2 additions and 2 deletions

View file

@ -11,7 +11,7 @@ module SystemCheck
# @param [Array<BaseCheck>] checks classes of corresponding checks to be executed in the same order
# @param [BaseExecutor] executor_klass optionally specifiy a different executor class
def self.run(component, checks = [], executor_klass = SimpleExecutor)
unless executor_klass.is_a? BaseExecutor
unless executor_klass < BaseExecutor
raise ArgumentError, 'Invalid executor'
end

View file

@ -17,7 +17,7 @@ module SystemCheck
#
# @param [BaseCheck] check class
def <<(check)
raise ArgumentError unless check.is_a? BaseCheck
raise ArgumentError unless check < BaseCheck
@checks << check
end
end