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.
11 12 13 14 |
# File 'lib/appraisal/dependency.rb', line 11 def initialize(name, requirements) @name = name @requirements = requirements end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
9 10 11 |
# File 'lib/appraisal/dependency.rb', line 9 def name @name end |
#requirements ⇒ Object
Returns the value of attribute requirements.
8 9 10 |
# File 'lib/appraisal/dependency.rb', line 8 def requirements @requirements end |
Instance Method Details
#for_dup ⇒ Object
:nodoc:
21 22 23 |
# File 'lib/appraisal/dependency.rb', line 21 def for_dup formatted_output Utils.format_arguments(requirements) end |
#to_s ⇒ Object
16 17 18 |
# File 'lib/appraisal/dependency.rb', line 16 def to_s formatted_output Utils.format_arguments(path_prefixed_requirements) end |