Class: Crspec::ProcessRunner::ChildFormatter

Inherits:
Object
  • Object
show all
Defined in:
lib/crspec/process_runner.rb

Overview

Streams marshalled Result structs to the parent as examples finish.

Instance Method Summary collapse

Constructor Details

#initialize(writer) ⇒ ChildFormatter

Returns a new instance of ChildFormatter.



271
272
273
274
# File 'lib/crspec/process_runner.rb', line 271

def initialize(writer)
  @writer = writer
  @mutex = Mutex.new
end

Instance Method Details

#example_failed(example) ⇒ Object



280
281
282
# File 'lib/crspec/process_runner.rb', line 280

def example_failed(example)
  emit(example, "failed")
end

#example_passed(example) ⇒ Object



276
277
278
# File 'lib/crspec/process_runner.rb', line 276

def example_passed(example)
  emit(example, "passed")
end

#example_pending(example) ⇒ Object



284
285
286
# File 'lib/crspec/process_runner.rb', line 284

def example_pending(example)
  emit(example, "pending")
end

#finishObject



289
# File 'lib/crspec/process_runner.rb', line 289

def finish; end

#startObject



288
# File 'lib/crspec/process_runner.rb', line 288

def start; end