Sha256: 6263074422e85249bc8527e16c6199064579bb4db8208970f360f48390937f80

Contents?: true

Size: 549 Bytes

Versions: 2

Compression:

Stored size: 549 Bytes

Contents

# frozen_string_literal: true

require 'rails_helper'

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

  before do
    matcher.from :from
    matcher.to   :to
  end

  context 'with no :with expectation' do
    specify do
      expect(matcher.description).to eq 'normalizy name from "from" to "to"'
    end
  end

  context 'with :with expectation' do
    before { matcher.with :blank }

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

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
normalizy-0.2.0 spec/normalizy/rspec/matcher/description_spec.rb
normalizy-0.1.0 spec/normalizy/rspec/matcher/description_spec.rb