Class: TurboTests::FakeExample

Inherits:
Struct
  • Object
show all
Defined in:
lib/turbo_tests.rb,
lib/turbo_tests.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#descriptionObject

Returns the value of attribute description

Returns:

  • (Object)

    the current value of description



55
56
57
# File 'lib/turbo_tests.rb', line 55

def description
  @description
end

#execution_resultObject

Returns the value of attribute execution_result

Returns:

  • (Object)

    the current value of execution_result



55
56
57
# File 'lib/turbo_tests.rb', line 55

def execution_result
  @execution_result
end

#full_descriptionObject

Returns the value of attribute full_description

Returns:

  • (Object)

    the current value of full_description



55
56
57
# File 'lib/turbo_tests.rb', line 55

def full_description
  @full_description
end

#locationObject

Returns the value of attribute location

Returns:

  • (Object)

    the current value of location



55
56
57
# File 'lib/turbo_tests.rb', line 55

def location
  @location
end

#location_rerun_argumentObject

Returns the value of attribute location_rerun_argument

Returns:

  • (Object)

    the current value of location_rerun_argument



55
56
57
# File 'lib/turbo_tests.rb', line 55

def location_rerun_argument
  @location_rerun_argument
end

#metadataObject

Returns the value of attribute metadata

Returns:

  • (Object)

    the current value of metadata



55
56
57
# File 'lib/turbo_tests.rb', line 55

def 
  
end

Class Method Details

.from_obj(obj) ⇒ Object



57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# File 'lib/turbo_tests.rb', line 57

def self.from_obj(obj)
   = obj[:metadata]

  [:shared_group_inclusion_backtrace].map! do |frame|
    RSpec::Core::SharedExampleGroupInclusionStackFrame.new(
      frame[:shared_group_name],
      frame[:inclusion_location]
    )
  end

  [:shared_group_inclusion_backtrace] = .delete(:shared_group_inclusion_backtrace)

  new(
    FakeExecutionResult.from_obj(obj[:execution_result]),
    obj[:location],
    obj[:description],
    obj[:full_description],
    ,
    obj[:location_rerun_argument]
  )
end

Instance Method Details

#notificationObject



79
80
81
82
83
# File 'lib/turbo_tests.rb', line 79

def notification
  RSpec::Core::Notifications::ExampleNotification.for(
    self
  )
end