Class: Appraisal::Dependency
- Inherits:
-
Object
- Object
- Appraisal::Dependency
- Defined in:
- lib/appraisal/dependency.rb
Overview
Dependency on a gem and optional version requirements
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#requirements ⇒ Object
Returns the value of attribute requirements.
Instance Method Summary collapse
-
#for_dup ⇒ Object
:nodoc:.
-
#initialize(name, requirements) ⇒ Dependency
constructor
A new instance of Dependency.
- #to_s ⇒ Object
Constructor Details
#initialize(name, requirements) ⇒ Dependency
Returns a new instance of Dependency.
9 10 11 12 |
# File 'lib/appraisal/dependency.rb', line 9 def initialize(name, requirements) @name = name @requirements = requirements end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
7 8 9 |
# File 'lib/appraisal/dependency.rb', line 7 def name @name end |
#requirements ⇒ Object
Returns the value of attribute requirements.
6 7 8 |
# File 'lib/appraisal/dependency.rb', line 6 def requirements @requirements end |
Instance Method Details
#for_dup ⇒ Object
:nodoc:
19 20 21 |
# File 'lib/appraisal/dependency.rb', line 19 def for_dup formatted_output Utils.format_arguments(requirements) end |
#to_s ⇒ Object
14 15 16 |
# File 'lib/appraisal/dependency.rb', line 14 def to_s formatted_output Utils.format_arguments(path_prefixed_requirements) end |