Class: Pact::Matchers::V3::Number
- Defined in:
- lib/pact/matchers/v3/number.rb
Instance Attribute Summary
Attributes inherited from Base
#kind, #opts, #spec_version, #template
Instance Method Summary collapse
-
#initialize(template) ⇒ Number
constructor
A new instance of Number.
Methods inherited from Base
Constructor Details
#initialize(template) ⇒ Number
Returns a new instance of Number.
7 8 9 10 11 12 13 14 |
# File 'lib/pact/matchers/v3/number.rb', line 7 def initialize(template) unless template.is_a?(Numeric) raise MatcherInitializationError, "#{self.class}: #{template} should be an instance of Numeric" end super(spec_version: Pact::Matchers::PACT_SPEC_V3, kind: 'number', template: template) end |