Class: RSpec::Core::Formatters::DeprecationFormatter::GeneratedDeprecationMessage Private
Do not use. This class is for internal use only.
Relationships & Source Files | |
Super Chains via Extension / Inclusion / Inheritance | |
Class Chain:
self,
Struct
|
|
Instance Chain:
self,
Struct
|
|
Inherits: |
Struct
|
Defined in: | rspec-core/lib/rspec/core/formatters/deprecation_formatter.rb |
Class Method Summary
- .new(data) ⇒ GeneratedDeprecationMessage constructor Internal use only
Instance Attribute Summary
- #type rw Internal use only
Instance Method Summary
- #to_s Internal use only
- #too_many_warnings_message Internal use only
Instance Attribute Details
#type (rw)
[ GitHub ]# File 'rspec-core/lib/rspec/core/formatters/deprecation_formatter.rb', line 94
GeneratedDeprecationMessage = Struct.new(:type)
Instance Method Details
#to_s
[ GitHub ]# File 'rspec-core/lib/rspec/core/formatters/deprecation_formatter.rb', line 100
def to_s msg = String.new("#{@data.deprecated} is deprecated.") msg << " Use #{@data.replacement} instead." if @data.replacement msg << " Called from #{@data.call_site}." if @data.call_site msg end
#too_many_warnings_message
[ GitHub ]# File 'rspec-core/lib/rspec/core/formatters/deprecation_formatter.rb', line 107
def "Too many uses of deprecated '#{type}'. #{DEPRECATION_STREAM_NOTICE}" end