Class: RSpec::Queue::QueueReporter
- Inherits:
-
SimpleDelegator
- Object
- SimpleDelegator
- RSpec::Queue::QueueReporter
- Defined in:
- lib/rspec/queue.rb
Instance Method Summary collapse
- #acknowledge ⇒ Object
- #cancel_run! ⇒ Object
-
#initialize(reporter, queue, example) ⇒ QueueReporter
constructor
A new instance of QueueReporter.
- #report_failure! ⇒ Object
- #report_success! ⇒ Object
- #requeue ⇒ Object
Constructor Details
#initialize(reporter, queue, example) ⇒ QueueReporter
Returns a new instance of QueueReporter.
331 332 333 334 335 |
# File 'lib/rspec/queue.rb', line 331 def initialize(reporter, queue, example) @queue = queue @example = example super(reporter) end |
Instance Method Details
#acknowledge ⇒ Object
356 357 358 |
# File 'lib/rspec/queue.rb', line 356 def acknowledge @queue.acknowledge(@example) end |
#cancel_run! ⇒ Object
349 350 351 352 353 354 |
# File 'lib/rspec/queue.rb', line 349 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
341 342 343 |
# File 'lib/rspec/queue.rb', line 341 def report_failure! @queue.report_failure! end |
#report_success! ⇒ Object
337 338 339 |
# File 'lib/rspec/queue.rb', line 337 def report_success! @queue.report_success! end |
#requeue ⇒ Object
345 346 347 |
# File 'lib/rspec/queue.rb', line 345 def requeue @queue.requeue(@example) end |