Class: RSpec::Queue::QueueReporter

Inherits:
SimpleDelegator
  • Object
show all
Defined in:
lib/rspec/queue.rb

Instance Method Summary collapse

Constructor Details

#initialize(reporter, queue, example) ⇒ QueueReporter

Returns a new instance of QueueReporter.



399
400
401
402
403
# File 'lib/rspec/queue.rb', line 399

def initialize(reporter, queue, example)
  @queue = queue
  @example = example
  super(reporter)
end

Instance Method Details

#acknowledgeObject



424
425
426
# File 'lib/rspec/queue.rb', line 424

def acknowledge
  @queue.acknowledge(@example)
end

#cancel_run!Object



417
418
419
420
421
422
# File 'lib/rspec/queue.rb', line 417

def cancel_run!
  # Remove the requeued example from the list of examples ran
  # Otherwise some formatters might break because the example state is reset
  examples.pop
  nil
end

#report_failure!Object



409
410
411
# File 'lib/rspec/queue.rb', line 409

def report_failure!
  @queue.report_failure!
end

#report_success!Object



405
406
407
# File 'lib/rspec/queue.rb', line 405

def report_success!
  @queue.report_success!
end

#requeueObject



413
414
415
# File 'lib/rspec/queue.rb', line 413

def requeue
  @queue.requeue(@example)
end