require 'pluginscan/file_finder' require 'pluginscan/reports/issues_report/issues_scanner' require 'pluginscan/reports/issues_report/issue_checks' module Pluginscan module Reports class IssuesReport def initialize(plugin_directory, printer = IssuesPrinter.new) found_files = FileFinder.new(plugin_directory) issues = IssuesScanner.new(THE_CHECKS).scan(found_files.php_files) @data = { issues: issues, file_count: found_files.count, } @printer = printer end def print @printer.print(@data) true end end end end