Class: Datadog::CI::Contrib::RSpec::Integration
Overview
Description of RSpec integration
Constant Summary
collapse
- MINIMUM_VERSION =
Gem::Version.new("3.0.0")
Instance Method Summary
collapse
Methods inherited from Integration
#available?, #configuration, #configure, #enabled, inherited, #late_instrument?, #patchable?, #patched?
Instance Method Details
#compatible? ⇒ Boolean
30
31
32
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 30
def compatible?
super && version >= MINIMUM_VERSION
end
|
#dependants ⇒ Object
15
16
17
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 15
def dependants
%i[knapsack ciqueue]
end
|
#loaded? ⇒ Boolean
23
24
25
26
27
28
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 23
def loaded?
!defined?(::RSpec).nil? && !defined?(::RSpec::Core).nil? &&
!defined?(::RSpec::Core::Example).nil? &&
!defined?(::RSpec::Core::Runner).nil? &&
!defined?(::RSpec::Core::ExampleGroup).nil?
end
|
#new_configuration ⇒ Object
34
35
36
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 34
def new_configuration
Configuration::Settings.new
end
|
#patcher ⇒ Object
38
39
40
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 38
def patcher
Patcher
end
|
#version ⇒ Object
19
20
21
|
# File 'lib/datadog/ci/contrib/rspec/integration.rb', line 19
def version
Gem.loaded_specs["rspec-core"]&.version
end
|