lib/brakeman/report.rb in brakeman-min-3.1.2 vs lib/brakeman/report.rb in brakeman-min-3.1.3

- old
+ new

@@ -4,18 +4,21 @@ #Tracker#run_checks. Be sure to +run_checks+ before generating #a report. class Brakeman::Report attr_reader :tracker - VALID_FORMATS = [:to_html, :to_pdf, :to_csv, :to_json, :to_tabs, :to_hash, :to_s, :to_markdown] + VALID_FORMATS = [:to_html, :to_pdf, :to_csv, :to_json, :to_tabs, :to_hash, :to_s, :to_markdown, :to_codeclimate] def initialize app_tree, tracker @app_tree = app_tree @tracker = tracker end def format format reporter = case format + when :to_codeclimate + require_report 'codeclimate' + Brakeman::Report::CodeClimate when :to_csv require_report 'csv' Brakeman::Report::CSV when :to_html require_report 'html'