Class: OasRails::Spec::License
- Inherits:
-
Object
- Object
- OasRails::Spec::License
- Includes:
- Specable
- Defined in:
- lib/oas_rails/spec/license.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(**kwargs) ⇒ License
constructor
A new instance of License.
- #oas_fields ⇒ Object
Methods included from Specable
Constructor Details
#initialize(**kwargs) ⇒ License
Returns a new instance of License.
8 9 10 11 |
# File 'lib/oas_rails/spec/license.rb', line 8 def initialize(**kwargs) @name = kwargs[:name] || 'GPL 3.0' @url = kwargs[:url] || 'https://www.gnu.org/licenses/gpl-3.0.html#license-text' end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/oas_rails/spec/license.rb', line 6 def name @name end |
#url ⇒ Object
Returns the value of attribute url.
6 7 8 |
# File 'lib/oas_rails/spec/license.rb', line 6 def url @url end |
Instance Method Details
#oas_fields ⇒ Object
13 14 15 |
# File 'lib/oas_rails/spec/license.rb', line 13 def oas_fields [:name, :url] end |