Class: QaServer::Scenarios
- Inherits:
-
Object
- Object
- QaServer::Scenarios
- Defined in:
- app/models/qa_server/scenarios.rb
Constant Summary collapse
- AUTHORITY_SCENARIO =
'authority'
- TERM_SCENARIOS =
'term'
- SEARCH_SCENARIOS =
'search'
Instance Attribute Summary collapse
-
#authority ⇒ Qa::Authorities::LinkedData::GenericAuthority
readonly
Authority instance the scenarios run against.
-
#authority_name ⇒ String
readonly
Name of the authority the scenarios run against (e.g. ‘agrovoc_direct’).
-
#search_scenarios ⇒ Array<SearchScenario>
readonly
The search scenarios to run against the authority.
-
#term_scenarios ⇒ Array<TermScenario>
readonly
The term scenarios to run against the authority.
Instance Method Summary collapse
-
#initialize(authority:, authority_name:, scenarios_config:) ⇒ Scenarios
constructor
A new instance of Scenarios.
Constructor Details
#initialize(authority:, authority_name:, scenarios_config:) ⇒ Scenarios
Returns a new instance of Scenarios.
27 28 29 30 31 32 33 |
# File 'app/models/qa_server/scenarios.rb', line 27 def initialize(authority:, authority_name:, scenarios_config:) @authority = @authority_name = @scenarios_config = scenarios_config parse_term_scenarios parse_search_scenarios end |
Instance Attribute Details
#authority ⇒ Qa::Authorities::LinkedData::GenericAuthority (readonly)
Returns authority instance the scenarios run against.
10 11 12 |
# File 'app/models/qa_server/scenarios.rb', line 10 def @authority end |
#authority_name ⇒ String (readonly)
Returns name of the authority the scenarios run against (e.g. ‘agrovoc_direct’).
13 14 15 |
# File 'app/models/qa_server/scenarios.rb', line 13 def @authority_name end |
#search_scenarios ⇒ Array<SearchScenario> (readonly)
Returns the search scenarios to run against the authority.
19 20 21 |
# File 'app/models/qa_server/scenarios.rb', line 19 def search_scenarios @search_scenarios end |
#term_scenarios ⇒ Array<TermScenario> (readonly)
Returns the term scenarios to run against the authority.
16 17 18 |
# File 'app/models/qa_server/scenarios.rb', line 16 def term_scenarios @term_scenarios end |