Sha256: 0339ba9c7abf465c78e55119d3260fbeaaac83e0238d3c7c816339d5370e4283

Contents?: true

Size: 521 Bytes

Versions: 9

Compression:

Stored size: 521 Bytes

Contents

module Remarkable
  module Specs
    module Matchers
      class BeAPersonMatcher < Remarkable::Base
        arguments

        optional :first_name
        optional :age, :default => 18
        optional :last_name, :alias => :family_name

        def description
          "be a person"
        end

        def expectation
          "is not a person"
        end
      end

      def be_a_person(*args, &block)
        BeAPersonMatcher.new(*args, &block).spec(self)
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
remarkable-3.0.0 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.1 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.2 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.3 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.4 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.5 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.6 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.7 spec/matchers/be_a_person_matcher.rb
remarkable-3.0.8 spec/matchers/be_a_person_matcher.rb