Sha256: 564ec9b656442e9b6067d1114c6c0b8f7e915c0304d893f3a2234d1afef316e0

Contents?: true

Size: 565 Bytes

Versions: 4

Compression:

Stored size: 565 Bytes

Contents

# frozen_string_literal: true

require 'rails_helper'

RSpec.describe Normalizy::RSpec::Matcher, '.description' do
  let!(:matcher) { described_class.new :name }

  context 'with no :with expectation' do
    it do
      matcher.from :from
      matcher.to   :to

      expect(matcher.description).to eq 'normalizy name from "from" to "to"'
    end
  end

  context 'with :with expectation' do
    it do
      matcher.with :blank

      matcher.from :from
      matcher.to   :to

      expect(matcher.description).to eq 'normalizy name with blank'
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
normalizy-1.5.0 spec/normalizy/rspec/matcher/description_spec.rb
normalizy-1.4.0 spec/normalizy/rspec/matcher/description_spec.rb
normalizy-1.3.0 spec/normalizy/rspec/matcher/description_spec.rb
normalizy-1.2.0 spec/normalizy/rspec/matcher/description_spec.rb