Class: Rosette::Core::Validators::RepoValidator
- Defined in:
- lib/rosette/core/validators/repo_validator.rb
Overview
Validates a repo by making sure it has been configured.
Instance Attribute Summary
Attributes inherited from Validator
Instance Method Summary collapse
-
#valid?(repo_name, _, configuration) ⇒ Boolean
Returns true if the repo is valid, false otherwise.
Methods inherited from Validator
Constructor Details
This class inherits a constructor from Rosette::Core::Validators::Validator
Instance Method Details
#valid?(repo_name, _, configuration) ⇒ Boolean
Returns true if the repo is valid, false otherwise
21 22 23 24 25 26 27 28 |
# File 'lib/rosette/core/validators/repo_validator.rb', line 21 def valid?(repo_name, _, configuration) if !configuration.get_repo(repo_name) << "Unable to find repo '#{repo_name}'." false else true end end |