Class: Maze::Hooks::LoggerHooks

Inherits:
Object
  • Object
show all
Defined in:
lib/maze/hooks/logger_hooks.rb

Overview

Hooks for Browser mode use

Class Method Summary collapse

Class Method Details

.after(scenario) ⇒ Object



14
15
16
17
18
# File 'lib/maze/hooks/logger_hooks.rb', line 14

def after(scenario)
  location = "\"# #{scenario.location}\""
  $logger.trace "--- End Scenario: #{scenario.name} #{location}"
  $logger.trace ''
end

.after_allObject



20
21
22
23
24
# File 'lib/maze/hooks/logger_hooks.rb', line 20

def after_all
  if ENV['BUILDKITE']
    FileUtils.mv("#{Dir.pwd}/#{Maze::Loggers::FileLogger::LOG_LOCATION}", "#{Dir.pwd}/maze_output/maze-runner.log")
  end
end

.before(scenario) ⇒ Object



8
9
10
11
12
# File 'lib/maze/hooks/logger_hooks.rb', line 8

def before(scenario)
  location = "\"# #{scenario.location}\""
  $logger.trace ''
  $logger.trace "\n--- Begin Scenario: #{scenario.name} #{location}"
end