Class: Fix::Run Private
- Inherits:
-
Object
- Object
- Fix::Run
- Defined in:
- lib/fix/run.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Run class.
Instance Attribute Summary collapse
-
#challenges ⇒ Array<::Defi::Method>
readonly
private
A list of challenges.
-
#environment ⇒ ::Fix::Dsl
readonly
private
A context instance.
-
#requirement ⇒ ::Spectus::Requirement::Base
readonly
private
An expectation.
Instance Method Summary collapse
-
#initialize(environment, requirement, *challenges) ⇒ Run
constructor
private
A new instance of Run.
-
#test(&subject) ⇒ ::Expresenter::Pass
private
Verify if the object checks the condition.
Constructor Details
#initialize(environment, requirement, *challenges) ⇒ Run
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Run.
22 23 24 25 26 |
# File 'lib/fix/run.rb', line 22 def initialize(environment, requirement, *challenges) @environment = environment @requirement = requirement @challenges = challenges end |
Instance Attribute Details
#challenges ⇒ Array<::Defi::Method> (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns A list of challenges.
17 18 19 |
# File 'lib/fix/run.rb', line 17 def challenges @challenges end |
#environment ⇒ ::Fix::Dsl (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns A context instance.
11 12 13 |
# File 'lib/fix/run.rb', line 11 def environment @environment end |
#requirement ⇒ ::Spectus::Requirement::Base (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns An expectation.
14 15 16 |
# File 'lib/fix/run.rb', line 14 def requirement @requirement end |
Instance Method Details
#test(&subject) ⇒ ::Expresenter::Pass
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Verify if the object checks the condition.
36 37 38 39 40 |
# File 'lib/fix/run.rb', line 36 def test(&subject) requirement.call { actual_value(&subject) } rescue ::Expresenter::Fail => e e end |