Class: Viperaptor::RambafileValidator
- Inherits:
-
Object
- Object
- Viperaptor::RambafileValidator
- Defined in:
- lib/viperaptor/helpers/rambafile.rb
Overview
Provides methods for validating Rambafile contents
Instance Method Summary collapse
-
#validate(path) ⇒ Void
Method validates Rambafile contents.
Instance Method Details
#validate(path) ⇒ Void
Method validates Rambafile contents
11 12 13 14 |
# File 'lib/viperaptor/helpers/rambafile.rb', line 11 def validate(path) file_contents = open(path).read preferences = file_contents.empty? ? {} : YAML.load(file_contents).to_hash end |