lib/simplabs/excellent/checks/cyclomatic_complexity_check.rb in excellent-1.7.2 vs lib/simplabs/excellent/checks/cyclomatic_complexity_check.rb in excellent-2.0.0
- old
+ new
@@ -6,13 +6,13 @@
module Checks
class CyclomaticComplexityCheck < Base #:nodoc:
- def initialize(interesting_contexts, threshold)
- super()
+ def initialize(interesting_contexts, options = {}) #:nodoc:
+ super(options)
@interesting_contexts = interesting_contexts
- @threshold = threshold
+ @threshold = options[:threshold].to_i
end
end
end