Class: Preek::SmellReporter
- Inherits:
-
Thor::Shell::Color
- Object
- Thor::Shell::Color
- Preek::SmellReporter
- Defined in:
- lib/preek/smell_reporter.rb
Overview
Here we report the smells in a nice fashion
Instance Method Summary collapse
-
#initialize(smelly_files, not_files) ⇒ SmellReporter
constructor
A new instance of SmellReporter.
- #print_smells ⇒ Object (also: #print_result)
Constructor Details
#initialize(smelly_files, not_files) ⇒ SmellReporter
Returns a new instance of SmellReporter.
5 6 7 8 9 |
# File 'lib/preek/smell_reporter.rb', line 5 def initialize(smelly_files, not_files) @smelly_files = smelly_files @not_files = not_files @padding = 0 end |
Instance Method Details
#print_smells ⇒ Object Also known as: print_result
11 12 13 14 15 16 17 18 |
# File 'lib/preek/smell_reporter.rb', line 11 def print_smells if success? say_status 'success!', 'No smells detected.' else print_each_smell end print_not_files end |