Class: Flakie::Reporters::TicTacToe
- Inherits:
-
Base
- Object
- Base
- Flakie::Reporters::TicTacToe
show all
- Defined in:
- lib/flakie/reporters/tic_tac_toe.rb
Constant Summary
collapse
- CHARACTER_SUCCESS =
"o"
- CHARACTER_FAILURE =
"x"
- CHARACTER_SUCCESS_COLORED =
"\e[32m#{CHARACTER_SUCCESS}\e[0m".freeze
- CHARACTER_FAILURE_COLORED =
"\e[31m#{CHARACTER_FAILURE}\e[0m".freeze
- CHARACTER_NEWLINE =
"\n"
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#close ⇒ Object
19
20
21
22
|
# File 'lib/flakie/reporters/tic_tac_toe.rb', line 19
def close
output.puts(CHARACTER_NEWLINE)
super
end
|
#open ⇒ Object
12
13
|
# File 'lib/flakie/reporters/tic_tac_toe.rb', line 12
def open
end
|
#report(report) ⇒ Object
15
16
17
|
# File 'lib/flakie/reporters/tic_tac_toe.rb', line 15
def report(report)
report.last_run.success? ? report_success : report_failure
end
|